Retrieves an aggregated count of devices in each status for a given command request.
Instead of listing every individual device status, this endpoint rolls the command's execution up into a count per state, for example how many devices are still queued versus how many succeeded or failed.
About Command Request Stats When a command request targets many devices or a group, tracking each device's status individually can be unwieldy. This endpoint returns the CommandRequestStats object, an array of state and total pairs, giving a quick read on how a command is progressing across its full target set without paging through every device status record.
Common Use Cases
Building a progress summary for a command that was issued to a large group
Quickly checking whether a command has finished executing across all targeted devices
Determining whether any devices have failed a command without listing them individually first
Best Practices
Use this endpoint for a high-level progress check, then fall back to GET /commands/v0/status/ with a request filter if you need the specific devices behind a given count
Poll this endpoint rather than the full status list when you only need aggregate numbers, to reduce response size
Workflow
Issue the command with POST /commands/v0/commands/ and capture the returned id
Poll this endpoint to track aggregate progress by state
If failures appear, filter GET /commands/v0/status/ by request and state to identify the specific devices
- Mock serverhttps://api.esper.io/_mock/openapi/commands/v0/commands/{id}/stats/
- https://develop-api.esper.cloud/apihttps://develop-api.esper.cloud/api/commands/v0/commands/{id}/stats/
curl -i -X GET \
'https://api.esper.io/_mock/openapi/commands/v0/commands/{id}/stats/' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'{ "code": 0, "message": "string", "content": { "id": "string", "status": [ … ] } }