Handlers
Get handler metrics
Read session counts by current status and accumulated cost for a saved handler.
TypeScript SDKThe npm client, generated from the API spec.Python SDKThe PyPI client, sync and async.
| Method | Path | Required permissions |
|---|---|---|
| GET | /v1/handlers/{handler_id}/metrics | read:sessions read:configs |
Token access
- API key
- Supported.
- CLI user token
- Supported.
- Sandbox token
- Requires the ellipsis:api scope and the required grants in the token's permissions.ellipsis configuration.
Higher permission levels include lower levels: read < write < delete.
Grant match patterns can further restrict access to individual resources.
Optional start and end timestamps filter session creation time, including start and excluding end. Cost includes the selected sessions' full history, in millicents. Requires configs:read matching handlers/{service} and unrestricted sessions:read.
Path parameters
handler_idstringrequired
Query parameters
startstring, date-time
Inclusive session creation-time bound. Naive timestamps use UTC.
endstring, date-time
Exclusive session creation-time bound. Naive timestamps use UTC.
curl "https://api.ellipsis.dev/v1/handlers/{handler_id}/metrics" \
-H "Authorization: Bearer $ELLIPSIS_API_TOKEN"import os
from ellipsis import Ellipsis
client = Ellipsis(api_key=os.environ["ELLIPSIS_API_TOKEN"])
result = client.handlers.metrics("...")
print(result)import { Ellipsis } from '@ellipsis-dev/sdk';
const client = new Ellipsis({
apiKey: process.env.ELLIPSIS_API_TOKEN!,
});
const result = await client.handlers.metrics('...');
console.log(result);Request
Response
Example response, 200
{
"cost": 0,
"end": "2026-01-01T00:00:00Z",
"handler_id": "string",
"start": "2026-01-01T00:00:00Z"
}