sondahub / Fleet API / Readings
Fake readings API
4,908 readings from the Fleet API, a fake IoT API. Telemetry. metrics is an object whose keys depend on the device type (a thermostat reports temperature, humidity and setpoint; a power meter voltage, current, power_kw and energy_kwh).
Reads with filters, sorting, search and relations; writes that answer like a real server and stay in your session token. Same ids on every build. Free, no key, CORS open.
Connect
- List
- https://api.sondahub.com/v1/fleet/readings
- One record
- https://api.sondahub.com/v1/fleet/readings/{id}
- OpenAPI 3
- https://api.sondahub.com/v1/fleet/openapi.json
- GraphQL
- https://api.sondahub.com/v1/fleet/graphql
- JSON file
- https://api.sondahub.com/data/fleet/readings.json
- MCP
- https://api.sondahub.com/mcp · list_records
curl "https://api.sondahub.com/v1/fleet/readings?limit=3"
Sample records
Records 1 to 3 of 4,908, exactly as GET /v1/fleet/readings/{id} answers them. The data file holds all of them.
[
{
"id": 1,
"created_at": "2026-09-01T11:54:28Z",
"updated_at": "2026-09-01T11:54:28Z",
"device_id": 1,
"recorded_at": "2026-09-01T11:54:28Z",
"metrics": {
"flow_lpm": 85.6,
"pressure_bar": 4,
"total_liters": 388793
},
"quality": "good"
},
{
"id": 2,
"created_at": "2026-09-01T11:54:59Z",
"updated_at": "2026-09-01T11:54:59Z",
"device_id": 1,
"recorded_at": "2026-09-01T11:54:59Z",
"metrics": {
"flow_lpm": 90.1,
"pressure_bar": 4.2,
"total_liters": 388812
},
"quality": "good"
},
{
"id": 3,
"created_at": "2026-09-01T11:55:27Z",
"updated_at": "2026-09-01T11:55:27Z",
"device_id": 1,
"recorded_at": "2026-09-01T11:55:27Z",
"metrics": {
"flow_lpm": 84.5,
"pressure_bar": 4.2,
"total_liters": 388842
},
"quality": "good"
}
]
Fields
| Field | Type | Notes |
|---|---|---|
idread-only | int | Assigned by the server. Seed records keep their ids across restarts; records you create continue after the seed. |
created_atread-only | datetime | When the record was created (ISO 8601, UTC). |
updated_atread-only | datetime | When the record last changed. |
device_idrequired | int → devices | |
recorded_atrequired | datetime | |
metricsrequired | json { [metric]: number | boolean } | |
quality | enum | good estimated suspect |
Relations: device → one device through device_id. Use ?expand=device to embed them, or the nested routes.
Endpoints
Try it
curl "https://api.sondahub.com/v1/fleet/readings?quality=estimated&expand=device&limit=3"
curl https://api.sondahub.com/v1/fleet/readings/1?expand=device
curl -i -X POST https://api.sondahub.com/v1/fleet/readings \
-H "Content-Type: application/json" \
-d '{"device_id":1,"recorded_at":"2026-09-30T12:00:00Z","metrics":{},"quality":"good"}'
curl "https://api.sondahub.com/v1/fleet/readings?sort=-id&limit=3" \ -H "X-Sondahub-Session: THE_TOKEN_FROM_THE_CREATE"
curl -X PATCH https://api.sondahub.com/v1/fleet/readings/1 \
-H "Content-Type: application/json" \
-d '{"quality":"estimated"}'
curl -X DELETE https://api.sondahub.com/v1/fleet/readings/4909 \ -H "X-Sondahub-Session: THE_TOKEN_FROM_THE_CREATE"
Query recipes
Every list option works on readings; these are ready to paste. All the options.
| What | Request |
|---|---|
| Page 2, 50 at a time (of 4,908) | /v1/fleet/readings?page=2&limit=50 |
| Only quality = good | /v1/fleet/readings?quality=good |
| Newest first by created at | /v1/fleet/readings?sort=-created_at&limit=5 |
| Only some fields | /v1/fleet/readings?fields=id,device_id&limit=5 |
| Embed the device | /v1/fleet/readings/1?expand=device |
| Just the count | /v1/fleet/readings?limit=1&fields=id |
GraphQL
The same readings as the readings query on https://api.sondahub.com/v1/fleet/graphql, and one reading as reading(id: 1). Introspection is on. More on the GraphQL API.
{
readings(limit: 3, sort: "-id", filter: { quality: good }) {
total
data {
id device_id recorded_at quality
device { serial }
}
}
}
curl https://api.sondahub.com/v1/fleet/graphql -H "Content-Type: application/json" -d '{"query": "{ readings(limit: 3, sort: \"-id\", filter: { quality: good }) { total data { id device_id recorded_at quality device { serial } } } }"}'
From an AI agent (MCP)
The MCP server reaches the same rows with list_records, get_record, create_record, update_record and delete_record, and as the resource sondahub://fleet/readings.
curl https://api.sondahub.com/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"list_records","arguments":{"api":"fleet","collection":"readings","filters":{"quality":"good"},"limit":3}}}'
More in the Fleet API
sites (40) · devices (500) · alerts (500) · commands (300)
The live streams, the MQTT broker, and the whole API on one page: Fleet API. Other worlds: fake e-commerce API, fake banking API, fake social media API, fake helpdesk API, fake flight booking API, fake user directory API.