{
"geo_country": {
"action": "allow",
"countries": ["US", "UK"],
"enabled": true
},
"geo_ip": {
"action": "block",
"ips": ["192.168.1.1", "10.0.0.1"],
"enabled": true
},
"token": {
"secret": "my_secret_token",
"enabled": true
},
"domain_referrer": {
"action": "allow",
"domains": ["example.com", "example.net"],
"enabled": false
}
}
/projects/<project_id>/access-controls
Authorization: Bearer ********************
{
"geo_country": {
"action": "allow",
"countries": ["US", "UK"],
"enabled": true
},
"geo_ip": {
"action": "block",
"ips": ["192.168.1.1", "10.0.0.1"],
"enabled": true
},
"token": {
"secret": "my_secret_token",
"enabled": true
},
"domain_referrer": {
"action": "allow",
"domains": ["example.com", "example.net"],
"enabled": false
}
}
curl --location --request PUT 'http://localhost:8080/v1/projects/66a1084b-4b6b-4001-a4ad-d34d13463068/access-controls' \
--header 'Content-Type: application/json' \
--data-raw '{
"geo_country": {
"action": "allow",
"countries": ["US", "UK"],
"enabled": true
},
"geo_ip": {
"action": "block",
"ips": ["192.168.1.1", "10.0.0.1"],
"enabled": true
},
"token": {
"secret": "my_secret_token",
"enabled": true
},
"domain_referrer": {
"action": "allow",
"domains": ["example.com", "example.net"],
"enabled": false
}
}'
{}