Skip to main content
POST
Create an app voice call
See Voice SDK integration for authentication, platform packages, routing, and preview availability. Enable Allow calls from apps in Settings → Voice & Telephony for this organization. Disabling it blocks new calls and activation of pending calls; active calls can finish. Call this endpoint from your authenticated server with a phone:write API key. Resolve contactId from the signed-in customer and choose an authorized destination: either { type: 'agent', id } or { type: 'team', id }. Reuse the UUID requestId for identical retries until activation. Changed settings or retries after activation return 409. maxDurationSeconds defaults to 1800 and accepts integers from 60 to 3600; the duration starts at activation. A successful response is HTTP 200 with callId, sessionId, controlToken, and expiresAt. Pass this object unchanged to the OpenCX SDK; it manages the audio connection internally. Audio connection URLs and participant credentials are not part of this response. Join and activate within two minutes. expiresAt is the outer call-control deadline, not an extension of that join window. Credentials must be returned only to the authenticated customer and must not be logged or cached. Creation returns 400 for invalid settings or unsupported agent transfers, 401 for invalid authentication, 403 for missing scope, disabled app calling, or a blocked contact, 404 for an unavailable contact/destination, 409 for conflicting or active calls, and 429 when requests are throttled.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
requestId
string<uuid>
required

Reuse for retries of the same call creation request.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
contactId
string
required

Verified contact belonging to your organization. Resolve this on your server.

Required string length: 1 - 100
destination
object
required
maxDurationSeconds
integer
default:1800
Required range: 60 <= x <= 3600

Response

Default Response

callId
string<uuid>
required
Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
sessionId
string<uuid>
required
Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
controlToken
string
required
expiresAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$