Skip to content

Latest commit

 

History

History
69 lines (49 loc) · 1.19 KB

File metadata and controls

69 lines (49 loc) · 1.19 KB

API

Authentication

All stateful HTTP endpoints expect:

Authorization: Bearer <driver_api_key>

The WebSocket endpoint uses a signed session token issued by the server.

GET /health

Returns:

{
  "status": "ok",
  "activeSessions": 0
}

POST /v1/proxy/session

Creates a new upstream Driver session and returns a public proxied CDP URL.

Example request:

{
  "country": "CA",
  "type": "hosted",
  "captchaSolver": true,
  "idleTimeoutMs": 120000,
  "maxDurationMs": 1800000
}

Example response:

{
  "success": true,
  "data": {
    "sessionId": "uuid",
    "upstreamSessionId": "sess_...",
    "mode": "actions",
    "cdpUrl": "wss://host/v1/proxy/connect/uuid?token=...",
    "expiresAt": "2026-03-24T22:00:00.000Z",
    "idleTimeoutMs": 120000,
    "maxDurationMs": 1800000
  }
}

GET /v1/proxy/session/:id

Returns session metadata for the owning org.

DELETE /v1/proxy/session/:id

Closes the hosted session and stops the upstream Driver browser session.

WS /v1/proxy/connect/:id?token=...

Connect a CDP client to the returned cdpUrl.

If the token is invalid, expired, or belongs to the wrong org, the connection is rejected.