Skip to content

Close alert

PUT /alert/<alertKs>/close

Description

Close an alert. An optional message can be provided. Success (204) is also returned when the alert is already closed .

Path parameters

Param Description
alertKs Alert key string (ks).

Body

Param Type Required Description
message string No Optional message (max 2000 characters, default empty).
isSolution boolean No Mark as a solution to the problem (requires a message of at least 60 characters unless configured diffrently by the infrasonar_alert_minimum_solution_length container property, default false).

Return codes

Error code Reason
204 Success.
400 Invalid body or alert key string.
401 Invalid or missing token.
403 Insufficient permissions (required: API+ALERT_CHANGE).

Example

Curl request:

curl \
    -X PUT 'https://api.infrasonar.com/alert/xxx/close' \
    -H 'Authorization: Bearer XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' \
    -H 'Content-Type: application/json' \
    --data-raw '{
    "message": "Closed using the API"
}'