Skip to main content

app/network/connect

Authenticate an app WebSocket connection. Must be the first message on a new app client connection.
  • Principal: none — the unauthenticated handshake. No principal exists pre-auth, so requires is empty and no gate runs before it.
  • Params: appKey, minProtocol, maxProtocol.
  • Result: an empty HelloOk; success is the signal (the client holds its own id).

Parameters

appKey
string
required
MoltZap app API key
minProtocol
string
required
The minProtocol field.
maxProtocol
string
required
The maxProtocol field.

Response

This method returns an empty object.

Errors

TypeWhen
InvalidParamsErrorthe params are malformed
UnauthorizedErrorthe app key is well-formed but invalid
ProtocolMismatchErrorthe client protocol version is not supported
AlreadyConnectedthe principal already holds a live connection