Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/sockudo/sockudo/llms.txt

Use this file to discover all available pages before exploring further.

Get Channel Users

GET
endpoint
Retrieve list of users in a presence channel

Authentication

Same authentication requirements as Trigger Event.

Path Parameters

appId
string
required
The application ID
channelName
string
required
The presence channel name (must start with presence-)

Query Parameters

Standard authentication query parameters only (auth_key, auth_timestamp, auth_version, auth_signature).

Response

users
array
Array of user objects in the presence channel

Examples

curl "https://api.example.com/apps/my-app/channels/presence-lobby/users?auth_key=key&auth_timestamp=1234567890&auth_version=1.0&auth_signature=abc123"

Response Examples

{
  "users": [
    {"id": "user-123"},
    {"id": "user-456"},
    {"id": "user-789"}
  ]
}

Terminate User Connections

POST
endpoint
Terminate all connections for a specific user

Authentication

Same authentication requirements as Trigger Event.

Path Parameters

appId
string
required
The application ID
userId
string
required
The user ID whose connections should be terminated

Query Parameters

Standard authentication query parameters only (auth_key, auth_timestamp, auth_version, auth_signature). Note: This endpoint typically does not have a request body. The body_md5 parameter should be omitted from authentication.

Response

ok
boolean
true if the termination request was processed successfully

Examples

curl -X POST "https://api.example.com/apps/my-app/users/user-123/terminate_connections?auth_key=key&auth_timestamp=1234567890&auth_version=1.0&auth_signature=abc123"

Response Examples

{
  "ok": true
}

Rate Limiting

Same rate limit headers as single event endpoint:
  • X-RateLimit-Limit - Maximum requests allowed per window
  • X-RateLimit-Remaining - Requests remaining in current window
  • X-RateLimit-Reset - Seconds until rate limit resets
  • Retry-After - Seconds to wait before retrying (when rate limited)

Error Codes

Status CodeDescription
200Success
400Bad Request (invalid channel name)
401Unauthorized (authentication failed)
404Application not found
500Internal Server Error (termination failed)

Notes

Get Channel Users

  • Only works with presence channels (names starting with presence-)
  • Returns all unique users currently subscribed to the channel
  • User IDs come from the channel authentication data provided during subscription
  • Multiple connections from the same user ID are counted only once

Terminate User Connections

  • Terminates all WebSocket connections associated with the user ID
  • Works across all channels the user is subscribed to
  • Termination is graceful - connections receive proper close frames
  • In horizontal scaling setups, termination propagates across all nodes via the adapter
  • User can reconnect immediately after termination (this is not a ban)
  • Useful for forcing logout, session invalidation, or security incident response