SIP Trunks

Create SIP trunk

Changed on

Creates a new SIP trunk.

post/v1/projects/{projectId}/trunks

Request

  • Base URL
    https://elastic-trunking.api.sinch.com
  • URL
    https://elastic-trunking.api.sinch.com/v1/projects/{projectId}/trunks
  • Auth
    • HTTP basic
    • or OAuth 2
      Client credentials
      Token URL: https://auth.sinch.com/oauth2/token

Path parameters

projectIdstring required
Example:3acb7ae1-cf3d-4112-ba5e-3a9d8c71cd47

The projectId is a required parameter you must include when making any API calls. You can find your project ID on your Build dashboard.

Request body

idstring

The SIP trunk id.

hostNamestring required

The host of the domain you would like to have for you trunk.

topLevelDomainstring

The top level domain to which the SIP trunk belongs.

domainstring

The fully qualified name of the domain, which is a combination of your 'hostName' and the 'topLevelDomain'.

namestring required

The friendly name of your SIP trunk.

callsPerSecondinteger nullable

Number of calls started per second. If null, the value is inherited from the service settings. To increase it, please contact your account manager.

enableCallerNameboolean

Enable caller name lookup for incoming calls. US and canada only.

callForwardNumberstring

The valid E.164 phone number that will be dialed on inbound calls when no SIP endpoints are available. Required if enableCallForward property is true.

enableCallForwardboolean

When enabled, if an inbound call can not be delivered to a SIP endpoint, calls will be forwarded to the configured callForwardNumber. To forward all calls without trying SIP, simply disable (or delete) all SIP endpoints on this trunk. Logs (and billing) will be created for 2 calls (inbound and outbound). Note: Since there is no SIP connection, PCAPs will not be generated.

createTimestring date-time

The date and time that the SIP trunk was created.

updateTimestring date-time

The date and time that the SIP trunk was last modified.

projectIdstring

The ID of the account.

Example request

{
  "hostName": "acme-domain-1",
  "topLevelDomain": ".elastic-sip.sinch.com",
  "domain": "acme-domain-1.elastic-sip.sinch.com",
  "name": "Acme Trunk",
  "callsPerSecond": 100,
  "enableCallerName": true,
  "callForwardNumber": "+17208511190",
  "enableCallForward": true,
  "createTime": "2022-01-01T00:00:00Z",
  "updateTime": "2022-01-01T00:00:00Z",
  "projectId": "1bf62742-7b84-4666-9cbe-8e5734fd57d0"
}

Response

SIP trunk created successfully

idstring

The SIP trunk id.

hostNamestring required

The host of the domain you would like to have for you trunk.

topLevelDomainstring

The top level domain to which the SIP trunk belongs.

domainstring

The fully qualified name of the domain, which is a combination of your 'hostName' and the 'topLevelDomain'.

namestring required

The friendly name of your SIP trunk.

callsPerSecondinteger nullable

Number of calls started per second. If null, the value is inherited from the service settings. To increase it, please contact your account manager.

enableCallerNameboolean

Enable caller name lookup for incoming calls. US and canada only.

callForwardNumberstring

The valid E.164 phone number that will be dialed on inbound calls when no SIP endpoints are available. Required if enableCallForward property is true.

enableCallForwardboolean

When enabled, if an inbound call can not be delivered to a SIP endpoint, calls will be forwarded to the configured callForwardNumber. To forward all calls without trying SIP, simply disable (or delete) all SIP endpoints on this trunk. Logs (and billing) will be created for 2 calls (inbound and outbound). Note: Since there is no SIP connection, PCAPs will not be generated.

createTimestring date-time

The date and time that the SIP trunk was created.

updateTimestring date-time

The date and time that the SIP trunk was last modified.

projectIdstring

The ID of the account.

Example response

{
  "hostName": "acme-domain-1",
  "topLevelDomain": ".elastic-sip.sinch.com",
  "domain": "acme-domain-1.elastic-sip.sinch.com",
  "name": "Acme Trunk",
  "callsPerSecond": 100,
  "enableCallerName": true,
  "callForwardNumber": "+17208511190",
  "enableCallForward": true,
  "createTime": "2022-01-01T00:00:00Z",
  "updateTime": "2022-01-01T00:00:00Z",
  "projectId": "1bf62742-7b84-4666-9cbe-8e5734fd57d0"
}

Changes

    • breaking

      the response property became nullable for the status

    • info

      the request optional property became not read-only

    • info

      the request property became nullable

    • info

      the response optional property became not read-only for the status

    • info

      endpoint added