Skip to content

Create admin IP allowlist entry

POST
/api/admin/ip-allowlist
Code sample: Shell / cURL
curl --request POST \
--url https://auth.example.com/api/admin/ip-allowlist \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "ip_range": "203.0.113.0/24", "description": "Office network", "enabled": true }'

Adds an IPv4, IPv6, or CIDR range to the admin IP allowlist. Duplicate ranges return a conflict error.

Media type application/json
object
ip_range
required
string
description
string
enabled
boolean
key
additional properties
Example
{
"ip_range": "203.0.113.0/24",
"description": "Office network",
"enabled": true
}

Admin IP allowlist entry.

Media type application/json
object
id
string
tenant_id
string
ip_range
string
ip_version
integer
Allowed values: 4 6
description
One of:
string
enabled
boolean
created_by
One of:
string
created_at
integer
updated_at
integer
key
additional properties
Example
{
"id": "ip_123",
"tenant_id": "tenant_123",
"ip_range": "203.0.113.0/24",
"ip_version": 4,
"description": "Office network",
"enabled": 1,
"created_by": "admin_123",
"created_at": 1770000000000,
"updated_at": 1770000000000
}

Error response.

Media type application/json
object
error
string
message
string
error_description
string
key
additional properties
Example generated
{
"error": "example",
"message": "example",
"error_description": "example"
}

Error response.

Media type application/json
object
error
string
message
string
error_description
string
key
additional properties
Example generated
{
"error": "example",
"message": "example",
"error_description": "example"
}