AsyncAPI channel · Nakama
· Nakama Realtime Socket API (WebSocket)
/ws
The single Nakama realtime WebSocket channel. All realtime traffic flows
as `Envelope` messages in both directions over this one connection. The
`publish` operation below covers envelopes the client sends to the server;
the `subscribe` operation covers envelopes the server sends to the client.
Provider:NakamaAsyncAPI: v2.6.0Spec: Nakama Realtime Socket API (WebSocket)Operations: 2Messages: 15
Channel address
/ws
Operations
publish
sendEnvelope
Client-to-server realtime messages.
subscribe
receiveEnvelope
Server-to-client realtime messages.
Messages
ChannelJoin
Client request to join a chat channel (room, direct message, or group).
Content-Type: application/json
ChannelMessageSend
Client request to send a message to a joined channel.
Content-Type: application/json
MatchCreate
Client request to create a new client-relayed multiplayer match.
Content-Type: application/json
MatchJoin
Client request to join a match by id or by matchmaker token.
Content-Type: application/json
MatchDataSend
Client sends an opcode-tagged data frame to all or some match participants.
Content-Type: application/json
MatchmakerAdd
Client request to enter the matchmaking pool with a query and constraints.
Content-Type: application/json
StatusUpdate
Client updates its presence status string.
Content-Type: application/json
Channel
Server reply describing a joined chat channel.
Content-Type: application/json
ChannelMessage
Server-initiated delivery of a message on a joined channel.
Content-Type: application/json
Match
Server reply describing a created or joined match, including presences.
Content-Type: application/json
MatchData
Server-initiated delivery of an opcode-tagged data frame from a match participant.
Content-Type: application/json
MatchmakerMatched
Server-initiated notification that a suitable set of opponents was found.
Content-Type: application/json
StatusPresenceEvent
Server-initiated event describing users who came online or went offline.
Content-Type: application/json
Notifications
Server-initiated delivery of one or more in-app notifications.
Content-Type: application/json
Error
Server error envelope, echoing the cid of the failed request when applicable.
Content-Type: application/json
About AsyncAPI
The AsyncAPI specification describes event-driven APIs the way OpenAPI describes request/response APIs. A channel is the named pipe — a webhook URL, a Kafka topic, a WebSocket route, an MQTT subject — that producers and consumers publish or subscribe to. Each channel carries one or more messages with structured payloads, and an operation declares whether a given party sends or receives on that channel.