Custom Rules
Create a custom rule
post/waap/v1/domains/{domain_id}/custom-rules
Path parameters
domain_idinteger required
The domain ID
The domain ID
Request body
Example request
{
"name": "Block foobar bot",
"action": {
"block": {
"action_duration": "12h"
}
},
"conditions": [
{
"url": {
"url": "/wp-admin/"
},
"user_agent": {
"user_agent": "curl/"
},
"header": {
"header": "Origin"
},
"header_exists": {
"header": "Origin"
},
"file_extension": {
"file_extension": [
"pdf"
]
},
"content_type": {
"content_type": [
"application/xml"
]
},
"organization": {
"organization": "UptimeRobot s.r.o"
},
"request_rate": {
"path_pattern": "/"
}
}
]
}Response
Successful Response
Example response
{
"name": "Block foobar bot",
"action": {
"block": {
"action_duration": "12h"
}
},
"conditions": [
{
"url": {
"url": "/wp-admin/"
},
"user_agent": {
"user_agent": "curl/"
},
"header": {
"header": "Origin"
},
"header_exists": {
"header": "Origin"
},
"file_extension": {
"file_extension": [
"pdf"
]
},
"content_type": {
"content_type": [
"application/xml"
]
},
"organization": {
"organization": "UptimeRobot s.r.o"
},
"request_rate": {
"path_pattern": "/"
}
}
]
}