Skip to content

WebSocketSessionError

Defined in: relay-sdks/ts/packages/relay-websocket/src/errors.ts:16

A session failure (TA-22): the session is over, or the dial failed.

  • Error
new WebSocketSessionError(message, options?): WebSocketSessionError;

Defined in: relay-sdks/ts/packages/relay-websocket/src/errors.ts:26

Parameter Type
message string
options? { cause?: unknown; close?: CloseInfo; }
options.cause? unknown
options.close? CloseInfo

WebSocketSessionError

Error.constructor

cause?: unknown;

Defined in: typescript/lib/lib.es2022.error.d.ts:24

Error.cause


readonly closeCode?: number;

Defined in: relay-sdks/ts/packages/relay-websocket/src/errors.ts:22

The peer’s application close code, when the peer closed the session (TA-24).


message: string;

Defined in: typescript/lib/lib.es5.d.ts:1075

Error.message


readonly name: "WebSocketSessionError" = 'WebSocketSessionError';

Defined in: relay-sdks/ts/packages/relay-websocket/src/errors.ts:18

Always 'WebSocketSessionError'; not part of the contract, which classifies by source.

Error.name


readonly reason?: string;

Defined in: relay-sdks/ts/packages/relay-websocket/src/errors.ts:24

The peer’s close reason, when the peer closed the session (TA-24).


readonly source: "session" = 'session';

Defined in: relay-sdks/ts/packages/relay-websocket/src/errors.ts:20

Always 'session'.


stack?: string;

Defined in: typescript/lib/lib.es5.d.ts:1076

Error.stack