Defjs
Core

WebSocketOutgoingData

Type accepted by WebSocket session send.

@defjs/core · Type

Signature

type WebSocketOutgoingData<TOutgoing extends AnyStruct | undefined> =
  TOutgoing extends AnyStruct ? StructInput<TOutgoing> : never;

The type session.send accepts: the StructInput of the endpoint's outgoing struct, or never when the endpoint declares none, so send cannot be called with a value.

Edit this page on GitHub
Released under the MIT License. · Copyright © 2026 MunMunMiao