Positions
1 operation at https://api.zaitrack.app. Request and response bodies are JSON with camelCase keys; ids are UUIDs; times are RFC 3339 in UTC.
Positions use the telemetry rate class, the tightest one: poll the latest position, or subscribe to webhooks for geofence entries and exits.
Every operation needs an API key, a personal access token or an OAuth access token unless it says otherwise. An Idempotency-Key is replayed for 24 hours; see Idempotency. Errors are application/problem+json; see Errors.
Latest position per device (?deviceId=…)
GET /v1/positions/latest
- Scope:
telemetry:readortelemetry:* - Rate class:
telemetry(10 per second and 180,000 per hour) - Idempotency-Key: not used
- Audited: no
- Step-up MFA: no
| Query parameter | Type | Notes |
|---|---|---|
deviceId | — |
Request
No body.
Response
200: fields the handler writes, taken from its source.
| Field | Type | Notes |
|---|---|---|
positions | array of object | |
positions[].deviceId | string | |
positions[].occurredAt | string (date-time) | |
positions[].lat | number | |
positions[].lon | number | |
positions[].speedKph | number | may be null |
positions[].headingDeg | number | may be null |
positions[].ignition | boolean | may be null |
Example
curl "https://api.zaitrack.app/v1/positions/latest" \
-H "Authorization: Bearer zk_test_…"