Subscribe to Device Events
Developing
Retrieve real-time events generated by devices, such as status changes or alerts.
Request
API key for authentication.
Body Params application/json
{
"device_type": "lock"
}
Request samples
curl --location --request GET '/devices/events' \
--header 'X-API-Key: your-api-key' \
--header 'Content-Type: application/json' \
--data-raw '{
"device_type": "lock"
}'
Responses
application/json
Successfully subscribed to events.
Example:2025-01-08T10:00:00Z
Additional event details.
Example:{"door_feedback":"open"}
{
"data": [
{
"eventType": "lockAlert",
"timestamp": "2025-01-08T10:00:00Z",
"details": {
"door_feedback": "open"
}
}
]
}
Modified at 2025-05-09 12:02:11