HTTP Global Settingsupdate zone http ipaccess setting

update zone http ipaccess setting

update zone http ipaccess setting

curl -X POST "https://api.5centscdn.com/v2/zones/http/settings/security/ipaccess" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_API_KEY" \
  -d '{
  "enabled": "Y",
  "policy": "Y",
  "list": "1.2.3.4,10.0.0.0/8",
  "ips": "1.1.1.1,192.168.1.10/30",
  "mode": "save"
}'
{
  "result": "success",
  "message": "Zone Settings Updated"
}
POST
/zones/http/settings/security/ipaccess
POST
Base URLstring

Target server for requests. Edit to use your own host.

API Key (header: X-API-Key)
X-API-Keystring
Required

API key (sent in header)

Content-Typestring
Required

The media type of the request body

Options: application/json
enabledstring

Enable or disable this feature. Y means enabled, N means disabled.

Options: Y, N
policystring

Y = Block listed IP addresses, N = Allow only listed IP addresses

Options: Y, N
liststring

Comma-separated IP addresses or CIDR ranges.

ipsstring

Comma-separated IPs excluded from access control.

modestring

Controls how the settings are applied to zones. save — only saves the settings, no changes will be made to existing zone settings. append — appends the values to existing zones data and updates. overwrite — overwrites the existing zones values, replacing them and updates.

Options: save, append, overwrite
Request Preview
Response

Response will appear here after sending the request

Authentication

header
X-API-Keystring
Required

API Key for authentication. Provide your API key in the header.

Body

application/json
enabledstring

Enable or disable this feature. Y means enabled, N means disabled.

Allowed values:YN
policystring

Y = Block listed IP addresses, N = Allow only listed IP addresses

Allowed values:YN
liststring

Comma-separated IP addresses or CIDR ranges.

Example:
1.2.3.4,10.0.0.0/8
ipsstring

Comma-separated IPs excluded from access control.

Example:
1.1.1.1,192.168.1.10/30
modestring

Controls how the settings are applied to zones. save — only saves the settings, no changes will be made to existing zone settings. append — appends the values to existing zones data and updates. overwrite — overwrites the existing zones values, replacing them and updates.

Allowed values:saveappendoverwrite

Responses

resultstring

Status of the API response.

messagestring

Human-readable status or result message