Skip to main content
GET
/
sessions
/
:id
Get Session
curl --request GET \
  --url https://api.example.com/sessions/:id
{
  "sessionId": "<string>",
  "slug": "<string>",
  "sessionToken": "<string>",
  "ownerToken": "<string>",
  "ownerUrl": "<string>",
  "overlayScriptUrl": "<string>",
  "publicUrl": "<string>",
  "edgeUrl": "<string>",
  "expiresAt": "<string>",
  "createdAt": "<string>",
  "authMode": "<string>",
  "policy": {
    "public": true,
    "maxConcurrentViewers": 123,
    "blockPaths": [
      "<string>"
    ],
    "password": "<string>"
  },
  "activeViewers": [
    {
      "id": "<string>",
      "lastSeenAt": "<string>",
      "requests": 123,
      "ip": "<string>"
    }
  ],
  "kickedViewerIds": [
    "<string>"
  ],
  "closed": true,
  "username": "<string>",
  "password": "<string>"
}
Retrieve session details by session ID or slug.

Get Session by ID

Endpoint

GET /sessions/:id

Path Parameters

id
string
required
The session ID (format: sess_<token>)

Response

sessionId
string
required
Unique session identifier
slug
string
required
Human-readable session slug
sessionToken
string
required
Combined authentication token
ownerToken
string
required
Owner authentication token
ownerUrl
string
required
Owner dashboard URL
overlayScriptUrl
string
required
Overlay script URL
publicUrl
string
required
Public session URL
edgeUrl
string
required
WebSocket edge URL
expiresAt
string
required
ISO 8601 expiration timestamp
createdAt
string
required
ISO 8601 creation timestamp
authMode
string
required
Authentication mode (none or basic)
policy
object
required
Session policy configuration
public
boolean
required
Whether the session is publicly accessible
maxConcurrentViewers
number
required
Maximum number of concurrent viewers allowed
blockPaths
string[]
required
Array of blocked URL paths
password
string
required
Viewer access password (empty string if none)
activeViewers
array
required
Array of currently active viewer objects
id
string
required
Viewer identifier
lastSeenAt
string
required
ISO 8601 timestamp of last activity
requests
number
required
Total number of requests made by this viewer
ip
string
Viewer IP address (optional)
kickedViewerIds
string[]
required
Array of viewer IDs that have been kicked
closed
boolean
required
Whether the session has been closed
username
string
Basic auth username (only when authMode is basic)
password
string
Basic auth password (only when authMode is basic)

Example Request

curl https://control.wormkey.io/sessions/sess_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6

Example Response

{
  "sessionId": "sess_a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6",
  "slug": "quiet-lime-42",
  "sessionToken": "quiet-lime-42.x7y8z9a0b1c2d3e4f5g6h7i8j9k0l1m2",
  "ownerToken": "x7y8z9a0b1c2d3e4f5g6h7i8j9k0l1m2",
  "ownerUrl": "https://wormkey.io/.wormkey/owner?slug=quiet-lime-42&token=x7y8z9a0b1c2d3e4f5g6h7i8j9k0l1m2",
  "overlayScriptUrl": "https://wormkey.io/.wormkey/overlay.js?slug=quiet-lime-42",
  "publicUrl": "https://wormkey.io/s/quiet-lime-42",
  "edgeUrl": "wss://wormkey.io/tunnel",
  "expiresAt": "2026-03-04T15:30:00.000Z",
  "createdAt": "2026-03-03T15:30:00.000Z",
  "authMode": "none",
  "policy": {
    "public": true,
    "maxConcurrentViewers": 20,
    "blockPaths": [],
    "password": ""
  },
  "activeViewers": [
    {
      "id": "viewer_abc123",
      "lastSeenAt": "2026-03-03T15:35:00.000Z",
      "requests": 42,
      "ip": "203.0.113.42"
    }
  ],
  "kickedViewerIds": [],
  "closed": false
}

Get Session by Slug

Endpoint

GET /sessions/by-slug/:slug

Path Parameters

slug
string
required
The session slug (format: adjective-noun-number)

Response

Returns the same session object structure as the ID-based endpoint above.

Example Request

curl https://control.wormkey.io/sessions/by-slug/quiet-lime-42

Error Response

Both endpoints return a 404 error if the session is not found:
{
  "error": "Session not found"
}

Build docs developers (and LLMs) love