Make an Outbound Call

Make an outbound call from an extension through a trunk of the PBX.

Conditions

  • The call will go through an outbound route, so the extension needs to have permission of dialing through that route.
  • Send the request to make an extension dial an external number.

    The extension will ring first, pick up the call on the extension and the external number will be dialed. If autoanswer is set to yes, the calling party will hear the ring back tone, the called party will hear the ringing.

Endpoint

POST /api/v1.1.0/extension/dial_outbound?token={token}

Request Parameters

Name Importance Type Description
extid Required Int The extension number.
outto Required String The external number.
autoanswer Optional String Whether to auto answer the call or not. This parameter requires the SIP phone to support.
  • yes
  • no

Response Parameters

Name Type Description
callid String A unique Identifier for the call.

Examples

Request Example

POST /api/v1.1.0/extension/dial_outbound?token=1e3b3ebb6a974cb42ed31de5413df52d HTTP/1.1
Content-Type:application/json; charset=utf-8
Host: api.yeastarcloud.com
{
    "extid": "1002",
    "outto": "971837373",
    "autoanswer": "no"
}
Response Example
HTTP/1.1 200 OK
Access-control-allow-origin: *
Access-control-allow-methods: GET, POST, OPTIONS, PUT, DELETE
{
    "status": "Success",
    "callid": "1495710387.333"
}