IP Ranges API

IP Range Operations

List all Access IP Ranges

SecuritybearerAuth
Request
query Parameters
filter[cidr_block]
string
filter[cidr_block][startswith]
string
filter[cidr_block][endswith]
string
filter[cidr_block][contains]
string
filter[status]
string (CloudflareSyncStatus)

An enumeration.

Enum: "pending" "added"
filter[created_at][gt]
string <date-time>
filter[created_at][lt]
string <date-time>
page[number]
integer
Default: 1
page[size]
integer <= 250
Default: 20
Responses
200

Successful Response

Response Schema: application/json
required
Array of objects (Data)
required
object (PaginationMeta)
422

Validation Error

Response Schema: application/json
Array of objects (Error)
Array
code
required
string <int>
detail
string
meta
object
object
title
required
string
get/access_ip_ranges
Request samples
import telnyx
telnyx.api_key = "YOUR_API_KEY"

telnyx.AccessIpRange.list(filter={"cidr_block":"string"},filter[cidr_block]={"startswith":"string"})
Response samples
application/json
{
  • "data": [
    • {
      • "cidr_block": "string",
      • "created_at": "2019-08-24T14:15:22Z",
      • "description": "string",
      • "id": "string",
      • "status": "pending",
      • "updated_at": "2019-08-24T14:15:22Z",
      • "user_id": "string"
      }
    ],
  • "meta": {
    • "page_number": 2,
    • "page_size": 25,
    • "total_pages": 3,
    • "total_results": 55
    }
}

Create new Access IP Range

SecuritybearerAuth
Request
Request Body schema: application/json
required
cidr_block
required
string (Cidr Block)
description
string (Description)
Responses
200

Successful Response

Response Schema: application/json
cidr_block
required
string (Cidr Block)
created_at
string <date-time> (Created At)
description
string (Description)
id
required
string (Id)
status
required
string (CloudflareSyncStatus)

An enumeration.

Enum: "pending" "added"
updated_at
string <date-time> (Updated At)
user_id
required
string (User Id)
422

Validation Error

Response Schema: application/json
Array of objects (Error)
Array
code
required
string <int>
detail
string
meta
object
object
title
required
string
post/access_ip_ranges
Request samples
application/json
{
  • "cidr_block": "string",
  • "description": "string"
}
Response samples
application/json
{
  • "cidr_block": "string",
  • "created_at": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "status": "pending",
  • "updated_at": "2019-08-24T14:15:22Z",
  • "user_id": "string"
}

Delete access IP ranges

SecuritybearerAuth
Request
path Parameters
access_ip_range_id
required
string
Responses
200

Successful Response

Response Schema: application/json
cidr_block
required
string (Cidr Block)
created_at
string <date-time> (Created At)
description
string (Description)
id
required
string (Id)
status
required
string (CloudflareSyncStatus)

An enumeration.

Enum: "pending" "added"
updated_at
string <date-time> (Updated At)
user_id
required
string (User Id)
delete/access_ip_ranges/{access_ip_range_id}
Request samples
import telnyx
telnyx.api_key = "YOUR_API_KEY"

res = telnyx.AccessIpRange.retrieve('access_ip_range_id')
res.delete()
Response samples
application/json
{
  • "cidr_block": "string",
  • "created_at": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "status": "pending",
  • "updated_at": "2019-08-24T14:15:22Z",
  • "user_id": "string"
}