Activate or deactivate CrowdSec firewall protection for your virtual server (VPS). Returns a `requestId` to track the operation's status in subsequent calls, ensuring correct protection configuration.
vmid integer · min: 1 required Example Unique vmid identifier
Accept Example Content-Type Example enable_protection boolean required success boolean timestamp string requestId string data object error string message string code string timestamp string requestId string https://cloud.hostup.se/api/vm/{vmid}/crowdsec curl -X POST "https://cloud.hostup.se/api/vm/17409/crowdsec" \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"enable_protection": true
}' {
"success": true,
"timestamp": "string",
"requestId": "string",
"data": {
"ips": [
"string"
],
"results": [
{
"ip": "string",
"success": true,
"message": "string"
}
],
"protection_active": true,
"total_ips": 0,
"success_count": 0,
"fail_count": 0,
"message": "string"
}
} {
"enable_protection": true
}