ReferenceRealtime
Create a one-time realtime websocket grant
Creates a short-lived, one-time grant for the /ws ActionCable endpoint. Authenticate with a bearer token or Session-Token/X-Nimbu-Session-Token; anonymous callers must provide site_id. The websocket protocol is documented separately in docs/realtime.md.
Header Parameters
Authorization?string
Bearer access token.
Session-Token?string
Customer session token. X-Nimbu-Session-Token is also accepted.
Request Body
application/json
Grant request payload
TypeScript Definitions
Use the request body type in TypeScript.
site_id?string
Required for anonymous grants when X-Nimbu-Site is unavailable.
Response Body
application/json
curl -X POST "https://example.com/realtime/grants" \ -H "Content-Type: application/json" \ -d '{}'{
"grant": "string",
"expires_at": "2019-08-24T14:15:22Z"
}Empty
Empty
Empty
Empty