Originate Telephony Call (Click-to-Call)
POST
/pbx/calls/originate
const url = 'https://pbx.ring2all.com/api/v1/pbx/calls/originate';const options = { method: 'POST', headers: {'X-API-Key': '<X-API-Key>', 'Content-Type': 'application/json'}, body: '{"source_extension":"1001","destination_number":"+13055551234","caller_id_number":"+18005550199","caller_id_name":"Ring2All Support"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://pbx.ring2all.com/api/v1/pbx/calls/originate \ --header 'Content-Type: application/json' \ --header 'X-API-Key: <X-API-Key>' \ --data '{ "source_extension": "1001", "destination_number": "+13055551234", "caller_id_number": "+18005550199", "caller_id_name": "Ring2All Support" }'Initiates a dual-leg outbound call bridging a SIP extension or agent with an external PSTN number.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
source_extension
required
string
Example
1001destination_number
required
string
Example
+13055551234caller_id_number
string
Example
+18005550199caller_id_name
string
Example
Ring2All SupportResponses
Section titled “ Responses ”Call initiated
Media typeapplication/json
object
call_uuid
string format: uuid
status
string
Example
{ "call_uuid": "4c520ef6-953e-4b68-b807-695c5d0f6ee8", "status": "originating"}
