Skip to main content
POST
Create a SIP Trunk

Inbound authentication

A trunk may use one inbound authentication scheme, or none. The two schemes are mutually exclusive, and are set through the inbound object. See Connecting to PolyAI Telephony for how callers present these on inbound calls.

Authorizations

X-API-Key
string
header
required

Path Parameters

account_id
string
required

ID of the account that owns the SIP Trunk.

Body

application/json

The owning account is taken from the URL path, not the body.

sip_cidr
string[]
required

The IPv4 CIDR blocks of your SIP servers.

Required array length: 1 - 10 elements
Maximum string length: 43
rtp_cidr
string[]
required

The IPv4 CIDR blocks of your RTP / media servers.

Required array length: 1 - 10 elements
Maximum string length: 43
name
string
required

A friendly name to help identify your SIP Trunk.

Required string length: 1 - 255
Pattern: \S
encrypted
boolean

Whether this SIP Trunk will handle encrypted (true; SIP over TCP/TLS, media over UDP/SRTP) or unencrypted (false; SIP over UDP, media over UDP/RTP) calls. Defaults to true when omitted.

inbound
object

Configuration for inbound calls. sip_auth and sip_token_auth are mutually exclusive.

outbound
object

Configuration for outbound calls leaving PolyAI.

Response

The created SIP Trunk.

A SIP Trunk.

id
string
required

PolyAI-generated SIP Trunk ID, e.g. tr-0123456789abcdefghijklmn.

account_id
string
required

The PolyAI account that owns the SIP Trunk.

sip_cidr
string[]
required

The IPv4 CIDR blocks of your SIP servers.

rtp_cidr
string[]
required

The IPv4 CIDR blocks of your RTP / media servers.

name
string
required

A friendly name to help identify your SIP Trunk.

encrypted
boolean
required

Whether this SIP Trunk will handle encrypted (true; SIP over TCP/TLS, media over UDP/SRTP) or unencrypted (false; SIP over UDP, media over UDP/RTP) calls.

inbound
object
required

Configuration for inbound calls.

created_at
string<date-time>
required

RFC 3339 timestamp of when the SIP Trunk was created.

updated_at
string<date-time>
required

RFC 3339 timestamp of when the SIP Trunk was last updated.

outbound
object

Configuration for outbound calls leaving PolyAI.

Last modified on July 30, 2026