POST
/api/public/v1/security/ip-whitelist

Add IP to whitelist

Whitelist an IPv4 or IPv6 address for the company.

Required scope

The access token must carry this scope. A token missing it gets 403 Forbidden. Grant them to an API client under Dev Tools → API, to an assistant or CLI sign-in when you approve or edit it under Dev Tools, and to a teammate under Employee → Permissions.

security:write

Request Body

PropertyTypeDescription
typestringAddress type.
addressstringIP address.
descriptionstringHuman label.
POSTExample request
curl
curl -X POST "https://www.pxb.app/api/public/v1/security/ip-whitelist" \
  -H "Authorization: Bearer your_access_token" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "IPV4",
    "address": "203.0.113.1",
    "description": "Office gateway"
  }'
200Example response
json
{
  "message": "IP address whitelisted successfully!",
  "content": {
    "entry": {
      "id": "ip_1",
      "type": "IPV4",
      "address": "203.0.113.1"
    }
  }
}

In the console

The same thing done by hand, for anyone comparing the API against the screen they already use.

Security → Whitelist
/security/whitelist
  1. Add an IP address with a label.