Create an IP address
const url = 'https://api.siprtc.io/v1/Accounts/example/SipTrunk/IPAclIPAddrs';const options = { method: 'POST', headers: {Authorization: 'Basic <credentials>', 'Content-Type': 'application/json'}, body: '{"cidr":"203.0.113.10","customer_auth_id":"AC000000000000000001","ip_acl_list_id":["0b8e7f4a-3c2d-4e1f-8a9b-7c6d5e4f3a01"]}'};
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://api.siprtc.io/v1/Accounts/example/SipTrunk/IPAclIPAddrs \ --header 'Authorization: Basic <credentials>' \ --header 'Content-Type: application/json' \ --data '{ "cidr": "203.0.113.10", "customer_auth_id": "AC000000000000000001", "ip_acl_list_id": [ "0b8e7f4a-3c2d-4e1f-8a9b-7c6d5e4f3a01" ] }'Creates an IP address record allowed to send calls through the IP access control lists it is put in. cidr must be a single IPv4 address in dotted form; prefix lengths such as /24 are rejected. The address must be unique on the account and an account can have at most 5 addresses. ip_acl_list_id puts it in those lists; IDs that do not exist are dropped. Vendor accounts can act for a direct child account with customer_auth_id.
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”Auth ID of your account.
Request Bodyrequired
Section titled “ Request Bodyrequired ”The address to create.
object
A single IPv4 address in dotted form. Prefix lengths (“/24”) are rejected.
Example
203.0.113.10Vendor accounts only: create the address for this direct child account.
Example
AC000000000000000001IDs of IP access control lists to put the address in. Unknown IDs are ignored.
Example
[ "0b8e7f4a-3c2d-4e1f-8a9b-7c6d5e4f3a01"]Responses
Section titled “ Responses ”The new IP address.
object
Auth ID of the account that owns the address.
The IPv4 address.
When the record was created (RFC 3339).
Auth ID of the account that created the record.
IP address record ID (UUID).
JSON-encoded array of the IP access control list IDs it belongs to, as stored.
The IP access control lists it belongs to, resolved to ID and name. Filled by GET only.
object
IP access control list ID.
IP access control list name.
Auth ID of the account that last changed the record.
Status of the address.
When the record was last changed (RFC 3339).
Example
{ "auth_id": "AC000000000000000000", "cidr": "203.0.113.10", "created_at": "2026-01-15T10:30:00Z", "created_by": "AC000000000000000000", "id": "5f4e3d2c-1b0a-4987-8f6e-5d4c3b2a1901", "ip_acl_list_id": "[\"0b8e7f4a-3c2d-4e1f-8a9b-7c6d5e4f3a01\"]", "ip_acl_list_ids": [ { "id": "0b8e7f4a-3c2d-4e1f-8a9b-7c6d5e4f3a01", "name": "Office IPs" } ], "modified_by": "AC000000000000000000", "status": "active", "updated_at": "2026-01-16T08:00:00Z"}Cidr is missing or not an IPv4 address, the limit is reached, the address exists, or the gateway did not supply your company (message “company id is empty”).
object
Human-readable explanation of the outcome.
Outcome of the request: “success” or “failed”.
Example
{ "message": "Invalid auth ID", "status": "success"}Missing or wrong Basic-auth credentials (returned by the API gateway).
Example generated
exampleCustomer_auth_id is not a direct child account of a vendor you belong to, or its parent is not a vendor.
object
Human-readable explanation of the outcome.
Outcome of the request: “success” or “failed”.
Example
{ "message": "Invalid auth ID", "status": "success"}The customer account could not be looked up.
object
Underlying error reported by the account lookup.
Human-readable explanation of the failure.
Always “failed”.
Example
{ "error": "account not found", "message": "Error fetching account details", "status": "failed"}