Skip to main content
POST
/
v1
/
calls
/
web
curl --request POST \
  --url https://api.oneinbox.ai/v1/calls/web \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "agent_id": "agt_abc123"
}
'
{
  "id": "call_abc123",
  "agent_id": "<string>",
  "type": "web",
  "room_name": "web-2006ff52",
  "server_url": "wss://voice.oneinbox.ai",
  "participant_token": "eyJhbGciOiJIUzI1NiJ9...",
  "created_at": "2023-11-07T05:31:56Z"
}

Documentation Index

Fetch the complete documentation index at: https://docs.oneinbox.ai/llms.txt

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

Authorizations

Authorization
string
header
required

Use api_key from POST /v1/api-keys

Body

application/json
agent_id
string
required
variables
object

Per-call template variables interpolated into the agent prompt.

Example:
{ "customer_name": "Suman" }
metadata
object

Free-form key/value pairs stored on the call record. Useful for passing CRM IDs, session data, or any context you want to retrieve later via GET /v1/calls/{id}.

Example:
{
"crm_contact_id": "ct_123",
"source": "website"
}
overrides
object

Response

201 - application/json

Created

id
string
Example:

"call_abc123"

agent_id
string
type
string
Example:

"web"

status
enum<string>
Available options:
queued,
initiated,
in_progress,
completed,
failed
room_name
string

Internal room name

Example:

"web-2006ff52"

server_url
string

WebSocket server URL (wss://voice.oneinbox.ai). Your frontend connects here using participant_token.

Example:

"wss://voice.oneinbox.ai"

participant_token
string
Example:

"eyJhbGciOiJIUzI1NiJ9..."

created_at
string<date-time>