Skip to main content
POST
/
collection
/
{collection_id}
/
capture
/
session
Create capture session
curl --request POST \
  --url https://api.videodb.io/collection/{collection_id}/capture/session \
  --header 'Content-Type: application/json' \
  --header 'x-access-token: <api-key>' \
  --data '
{
  "end_user_id": "user-123",
  "callback_url": "https://webhook.example.com/callback",
  "ws_connection_id": "conn-123",
  "metadata": {}
}
'
{
  "success": true,
  "data": {
    "session_id": "capture-12345",
    "end_user_id": "user-123",
    "status": "created",
    "collection_id": "default",
    "ws_connection_id": "conn-123",
    "metadata": {},
    "created_at": "2023-11-07T05:31:56Z"
  }
}
Create a new capture session within a collection. Capture sessions enable real-time media ingestion from client applications.
  • end_user_id is required to identify the end user
  • Use ws_connection_id to link to an existing WebSocket connection for real-time updates
  • Use metadata to attach custom key-value data to the session

Authorizations

x-access-token
string
header
required

API key for authentication (sk-xxx format)

Path Parameters

collection_id
string
required
Example:

"default"

Body

application/json
end_user_id
string
required
Example:

"user-123"

callback_url
string
Example:

"https://webhook.example.com/callback"

ws_connection_id
string
Example:

"conn-123"

metadata
object

Response

Capture session created

success
boolean
Example:

true

data
object