Skip to navigation

Create WebRTC call

Starts a browser call against the published version of a flow and assigns an agent to it. Send the SDP offer next with POST /api/v1/calls/webrtc/{callId}/offer. To try unpublished changes, use POST /api/v1/calls/webrtc/test. The call is billed like any other call and needs a positive balance.

Authentication

AuthorizationBearer

Pass a JWT access token or an API key (prefixed with tif_live_) as a Bearer token.

Request

This endpoint expects an object.
flowIdstringRequiredformat: "uuid"
Flow ID to use for the AI conversation
metadataobject or nullOptional
Additional metadata to attach to the call

Response

WebRTC call created
callIdstringformat: "uuid"
Unique call identifier
flowIdstringformat: "uuid"
Flow ID used for the AI conversation
statusenum
Current call status
botIdstring or nullOptional
Identifier of the agent instance serving the call, if one is assigned yet
offerDeadlineAtstring or nullOptional

The agent waits for your SDP offer until this time (RFC 3339), then releases itself and the call can no longer start. Send the offer well before it: connecting still takes a few seconds after the offer. Absent when no agent is assigned or the agent did not report its window.

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
429
Too Many Requests Error
500
Internal Server Error
503
Service Unavailable Error