PUT /alarms/:id/close
Closes an alarm. Has no effect if the alarm has already been closed.
This request is idempotent.
curl -XPUT \
--header "Content-Type: application/json" \
--header "Authorization: Bearer 4b1e8df2ff50110ca86e28f2b499facbd78310c9cda0125543ad80ac70cc28d1" \
https://api.invisiblecollector.com/v1/alarms/1fb0c683-bedc-45be-a88a-ff76da7bf650/close --data '{}'
require 'invisible_collector'
client = InvisibleCollector::API.new(api_token: '4a415cc660e67d8f4d26d5a7f390183a86fc3a4524ded78dc2448e86c48b2739')
alarm = client.alarm.get(id)
client.alarm.close(alarm)
Errors
This endpoint may return the following errors:
HTTP Code | Description |
---|---|
401 Unauthorized | Invalid credentials were supplied |
404 Not Found | The alarm was not found. |