Sirius Scan uses standard HTTP status codes and returns JSON error responses to indicate problems with API requests.
API errors return a JSON object with an error field containing a human-readable message:
{
"error": "description of what went wrong"
}
The API uses standard HTTP status codes to indicate the success or failure of requests:
| Status Code | Description |
|---|---|
| 200 | Success |
| 400 | Bad request - invalid parameters |
| 401 | Unauthorized - invalid or missing API key |
| 404 | Resource not found |
| 500 | Internal server error |
Returned when the X-API-Key header is missing or contains an invalid key:
{
"error": "Invalid API key"
}
Returned when a requested host or vulnerability does not exist:
{
"error": "Host not found"
}
Returned when the request body is malformed or missing required fields:
{
"error": "Failed to parse request body"
}
error field from JSON responses for user-facing messages