Trunks
Manage your trunks.
Retrieve a collection of providers
Use the filter query parameter to retrieve just a subset of a collection.
Use the search query parameter to restrict the results of a request to match a search criterion.
Use the orderby query parameter to specify the sort order of the items returned from server.
The default order is ascending order.
Use the skip query parameter to set the number of items to skip at the start of a collection.
0Use the top query parameter to specify the page size of the result set.
100OK
Total number of resource.
100Error
GET /api/providers HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"count": 1,
"items": [
{
"id": "xxxxxx",
"name": "example",
"enabled": true,
"brand": "Generic",
"auth_mode": "REGISTER_AUTH",
"transport": "UDP",
"hostname": "example",
"port": 1000,
"auth_id": "xxxxxx",
"username": "example",
"registration": false,
"register_interval": 600,
"outbound_server": "",
"outbound_server_port": 1000,
"inlan": false,
"single_via_header": true,
"rewrite_via_ip": false,
"verify_port": true,
"keep_alive": true,
"keep_alive_interval": 360,
"concurrency": 100,
"additional_ips": "",
"adjust_sdp_direction": false,
"remove_srtp_info": true,
"remove_plus_prefix": false,
"stir_shaken_signature_required": false,
"tel_uri_scheme_for_request_line": false,
"tel_uri_scheme_for_to_header": false,
"did_numbers": "1000-2000",
"inbound_parameters": {
"caller_num": "DEFAULT",
"caller_display_name": "DEFAULT",
"called_num": "DEFAULT",
"privacy_types_supported": "DEFAULT",
"enable_stir_shaken_validation": false,
"pai_header_parameter_name": "verstat",
"drop_calls_with_verification_status": [],
"pass_api_header_to_uad": false
},
"outbound_parameters": {
"request_line_uri_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"request_line_uri_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"to_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"from_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"from_user_part": {
"value": "OUTBOUND_CALLER_ID",
"custom_value": ""
},
"from_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"privacy_types_supported": "DEFAULT"
},
"shared": false,
"custom_headers": {
"add": [
{
"name": "example",
"value": "xxxxxx"
}
],
"relay": [
{
"name": "example"
}
]
}
}
]
}Add a new provider into system.
The name of the trunk.
Whether to enable the provider.
trueThe brand of trunk.
Authentication mode:
Can be either:
IP_AUTH:REGISTER_AUTH:ACCEPT_REGISTER:TEAMS:WHATS_APP:
The trunk transport protocol:
Can be either:
UDP:TCP:TLS:
Server hostname or IP address
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535. For TCP, port number 0 is reserved and cannot be used, while for UDP, the source port is optional and a value of zero means no port
80Authentication ID, i.e. SIP username.
Authentication username.
Password for authentication.
Whether registration is required.
trueInterval for registry refreshment, in seconds.
600The outbound server hostname of the trunk.
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535. For TCP, port number 0 is reserved and cannot be used, while for UDP, the source port is optional and a value of zero means no port
80Whether the trunk under LAN or not.
falseWhether this trunk is only accept single Via SIP header or not.
trueRewrite the host IP of Via header by public IP when sending the request to trunk.
trueVerify the port when receiving SIP messages from trunk
trueSend OPTIONS message for keep alive.
trueThe max number of concurrent calls.
Keep alive message sending interval (seconds).
360The additional IP addresses of provider.
A semicolon-separated list of IP addresses in CIDR format.
For example: 192.0.2.0/24;192.0.2.0/32 as defined in RFC 4632 and RFC 4291.
Adjust the SDP direction for call hold.
falseRemove crypto line in the SDP.
trueRemove the "+" prefix from the called number on outbound calls.
trueWhether to enable STIR/SHAKEN signature.
falseWhether to Use the Tel URI scheme for the Request Line.
falseWhether to Use the Tel URI scheme for the To header.
falseThe semicolon-separated list of DID/DDI pool number range or DID/DDI number. Assign a DID/DDI pool number range or DID/DDI number to the tenant. For example: 3000;12000-18000. The DID/DDI pool number range should not overlap with other tenant DID/DDI pool number ranges and numbers.
Whether to force outbound traffic to be routed through the outbound proxy.
trueCreated
NzAwNTUxOTA5NzczMTQ4MTYwError
POST /api/providers HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 2813
{
"name": "example",
"enabled": true,
"brand": "Generic",
"auth_mode": "REGISTER_AUTH",
"transport": "UDP",
"hostname": "example",
"port": 1000,
"auth_id": "xxxxxx",
"username": "user",
"password": "xxxxxx",
"registration": false,
"register_interval": 600,
"outbound_server": "",
"outbound_server_port": 1000,
"inlan": false,
"single_via_header": true,
"rewrite_via_ip": false,
"verify_port": true,
"keep_alive": true,
"concurrency": 100,
"keep_alive_interval": 360,
"additional_ips": "",
"adjust_sdp_direction": false,
"remove_srtp_info": true,
"remove_plus_prefix": false,
"stir_shaken_signature_required": false,
"tel_uri_scheme_for_request_line": false,
"tel_uri_scheme_for_to_header": false,
"did_numbers": "1000-2000",
"inbound_parameters": {
"caller_num": "DEFAULT",
"caller_display_name": "DEFAULT",
"called_num": "DEFAULT",
"privacy_types_supported": "DEFAULT",
"enable_stir_shaken_validation": false,
"pai_header_parameter_name": "verstat",
"drop_calls_with_verification_status": [],
"pass_api_header_to_uad": false
},
"outbound_parameters": {
"request_line_uri_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"request_line_uri_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"to_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"from_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"from_user_part": {
"value": "OUTBOUND_CALLER_ID",
"custom_value": ""
},
"from_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"privacy_types_supported": "DEFAULT"
},
"custom_headers": {
"add": [
{
"name": "example",
"value": "xxxxxx"
}
],
"relay": [
{
"name": "example"
}
]
}
}{
"id": "xxxxxxxx"
}Get details of a provider by it's unique ID.
NzAwNTUxOTA5NzczMTQ4MTYwOK
NzAwNTUxOTA5NzczMTQ4MTYwThe name of the trunk.
Whether to enable the provider.
trueThe brand of trunk.
Authentication mode:
Can be either:
IP_AUTH:REGISTER_AUTH:ACCEPT_REGISTER:TEAMS:WHATS_APP:
The trunk transport protocol:
Can be either:
UDP:TCP:TLS:
Server hostname or IP address
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535. For TCP, port number 0 is reserved and cannot be used, while for UDP, the source port is optional and a value of zero means no port
80Authentication ID, i.e. SIP username.
Authentication username.
Whether registration is required.
trueInterval for registry refreshment, in seconds.
600The outbound server hostname of the trunk.
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535. For TCP, port number 0 is reserved and cannot be used, while for UDP, the source port is optional and a value of zero means no port
80Whether the trunk under LAN or not.
falseWhether this trunk is only accept single Via SIP header or not.
trueRewrite the host IP of Via header by public IP when sending the request to trunk.
trueVerify the port when receiving SIP messages from trunk
trueSend OPTIONS message for keep alive.
trueKeep alive message sending interval (seconds).
360The max number of concurrent calls.
The additional IP addresses of provider.
A semicolon-separated list of IP addresses in CIDR format.
For example: 192.0.2.0/24;192.0.2.0/32 as defined in RFC 4632 and RFC 4291.
Adjust the SDP direction for call hold.
falseRemove crypto line in the SDP.
trueRemove the "+" prefix from the called number on outbound calls.
trueWhether to enable STIR/SHAKEN signature.
falseWhether to Use the Tel URI scheme for the Request Line.
falseWhether to Use the Tel URI scheme for the To header.
falseThe semicolon-separated list of DID/DDI pool number range or DID/DDI number. Assign a DID/DDI pool number range or DID/DDI number to the tenant. For example: 3000;12000-18000. The DID/DDI pool number range should not overlap with other tenant DID/DDI pool number ranges and numbers.
The flag of whether the trunk is shared.
Whether to force outbound traffic to be routed through the outbound proxy.
trueError
GET /api/providers/{id} HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"id": "xxxxxx",
"name": "example",
"enabled": true,
"brand": "Generic",
"auth_mode": "REGISTER_AUTH",
"transport": "UDP",
"hostname": "example",
"port": 1000,
"auth_id": "xxxxxx",
"username": "user",
"registration": false,
"register_interval": 600,
"outbound_server": "",
"outbound_server_port": 1000,
"inlan": false,
"single_via_header": true,
"rewrite_via_ip": false,
"verify_port": true,
"keep_alive": true,
"keep_alive_interval": 360,
"concurrency": 100,
"additional_ips": "",
"adjust_sdp_direction": false,
"remove_srtp_info": true,
"remove_plus_prefix": false,
"stir_shaken_signature_required": false,
"tel_uri_scheme_for_request_line": false,
"tel_uri_scheme_for_to_header": false,
"did_numbers": "1000-2000",
"inbound_parameters": {
"caller_num": "DEFAULT",
"caller_display_name": "DEFAULT",
"called_num": "DEFAULT",
"privacy_types_supported": "DEFAULT",
"enable_stir_shaken_validation": false,
"pai_header_parameter_name": "verstat",
"drop_calls_with_verification_status": [],
"pass_api_header_to_uad": false
},
"outbound_parameters": {
"request_line_uri_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"request_line_uri_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"to_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"from_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"from_user_part": {
"value": "OUTBOUND_CALLER_ID",
"custom_value": ""
},
"from_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"privacy_types_supported": "DEFAULT"
},
"shared": false,
"custom_headers": {
"add": [
{
"name": "example",
"value": "xxxxxx"
}
],
"relay": [
{
"name": "example"
}
]
}
}Update properties of provider by it's unique ID.
NzAwNTUxOTA5NzczMTQ4MTYwThe name of the trunk.
Whether to enable the provider.
trueThe trunk transport protocol:
Can be either:
UDP:TCP:TLS:
Server hostname or IP address
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535. For TCP, port number 0 is reserved and cannot be used, while for UDP, the source port is optional and a value of zero means no port
80Authentication ID, i.e. SIP username.
Authentication username.
Password for authentication.
Whether registration is required.
trueInterval for registry refreshment, in seconds.
600The outbound server hostname of the trunk.
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535. For TCP, port number 0 is reserved and cannot be used, while for UDP, the source port is optional and a value of zero means no port
80Whether the trunk under LAN or not.
falseWhether this trunk is only accept single Via SIP header or not.
trueRewrite the host IP of Via header by public IP when sending the request to trunk.
trueVerify the port when receiving SIP messages from trunk
trueSend OPTIONS message for keep alive.
trueKeep alive message sending interval (seconds).
360The max number of concurrent calls.
The additional IP addresses of provider.
A semicolon-separated list of IP addresses in CIDR format.
For example: 192.0.2.0/24;192.0.2.0/32 as defined in RFC 4632 and RFC 4291.
Adjust the SDP direction for call hold.
falseRemove crypto line in the SDP.
trueRemove the "+" prefix from the called number on outbound calls.
trueWhether to enable STIR/SHAKEN signature.
falseWhether to Use the Tel URI scheme for the Request Line.
falseWhether to Use the Tel URI scheme for the To header.
falseThe semicolon-separated list of DID/DDI pool number range or DID/DDI number. Assign a DID/DDI pool number range or DID/DDI number to the tenant. For example: 3000;12000-18000. The DID/DDI pool number range should not overlap with other tenant DID/DDI pool number ranges and numbers.
Whether to force outbound traffic to be routed through the outbound proxy.
trueOK
No content
Error
POST /api/providers/{id} HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 2767
{
"name": "example",
"enabled": true,
"transport": "UDP",
"hostname": "example",
"port": 1000,
"auth_id": "xxxxxx",
"username": "user",
"password": "xxxxxx",
"registration": false,
"register_interval": 600,
"outbound_server": "",
"outbound_server_port": 1000,
"inlan": false,
"single_via_header": true,
"rewrite_via_ip": false,
"verify_port": true,
"keep_alive": true,
"keep_alive_interval": 360,
"concurrency": 100,
"additional_ips": "",
"adjust_sdp_direction": false,
"remove_srtp_info": true,
"remove_plus_prefix": false,
"stir_shaken_signature_required": false,
"tel_uri_scheme_for_request_line": false,
"tel_uri_scheme_for_to_header": false,
"did_numbers": "1000-2000",
"inbound_parameters": {
"caller_num": "DEFAULT",
"caller_display_name": "DEFAULT",
"called_num": "DEFAULT",
"privacy_types_supported": "DEFAULT",
"enable_stir_shaken_validation": false,
"pai_header_parameter_name": "verstat",
"drop_calls_with_verification_status": [],
"pass_api_header_to_uad": false
},
"outbound_parameters": {
"request_line_uri_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"request_line_uri_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"contact_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"to_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"to_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"from_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"from_user_part": {
"value": "OUTBOUND_CALLER_ID",
"custom_value": ""
},
"from_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_called_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"remote_party_id_calling_party_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_asserted_identity_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_preferred_identify_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_display_name": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_user_part": {
"value": "DEFAULT",
"custom_value": ""
},
"p_called_party_id_host_part": {
"value": "DEFAULT",
"custom_value": ""
},
"privacy_types_supported": "DEFAULT"
},
"custom_headers": {
"add": [
{
"name": "example",
"value": "xxxxxx"
}
],
"relay": [
{
"name": "example"
}
]
}
}No content
Get status of provider by it's unique ID.
NzAwNTUxOTA5NzczMTQ4MTYwSuccess
Trunk status includes:
ONLINE:OFFLINE:
Error
GET /api/providers/{id}/status HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"status": "ONLINE"
}Destroy provider by it's unique ID.
NzAwNTUxOTA5NzczMTQ4MTYwNo Content
No content
Invalid provider ID supplied.
Provider is still referenced by an inbound or outbound rule (RESOURCE_IN_USE).
POST /api/providers/{id}/destroy HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
Export a collection of providers to file.
OK
Error
GET /api/providers/export HTTP/1.1
Host: HOSTNAME:8887
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
binaryLast updated
Was this helpful?