A PartyKit room channel. The `party` segment identifies which Party class to route to (defaults to `main`), and the `room` segment is the room id. The PartyKit runtime guarantees that every connection using the same `room` id is routed to the same Durable Object instance, so a room represents a single, isolated, stateful server. Clients open a WebSocket against this path; the server invokes `onCon
party — The name of the Party (Party.Server class) to route to. PartyKit defaults this to `main` when omitted by the client.
room — The room id. Connections sharing the same room id are routed to the same party instance (Durable Object).
Operations
publish
clientSendMessage
Client sends a message to the party.
subscribe
serverPushMessage
Server pushes a message to the client.
Messages
ClientMessage
An inbound message from a connected client.
Content-Type: application/json
ServerMessage
A targeted message sent by the party to one connection.
Content-Type: application/json
BroadcastMessage
A message fanned out by the party to all connected clients via `Room.broadcast()`. The party may pass an optional list of connection ids to exclude from delivery.
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.
Discovery needs no key. Ratings and market analysis are Pro.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. See our Privacy Policy and
Terms.