Developers
PocketTrack API
Pull your machines, status history, maintenance logs, parts requests, warranty claims, refund requests and reminders into your own dashboards, spreadsheets and reports. Read-only, JSON over HTTPS, no SDK required.
1. Get a key
An admin creates keys in Settings → API Keys. The key is shown once; copy it somewhere safe. Keys belong to your organization, not to a person, so they keep working when staff change. Revoke a key from the same page and it stops working immediately.
Read keys are available to every organization. Write access (changing machine status, adding notes, resolving refunds) is enabled per organization on request. Contact us and tell us what you are building.
2. Authenticate
Send the key as a bearer token on every request. The base URL is https://pockettrack.app/api/v1.
curl https://pockettrack.app/api/v1/summary \
-H "Authorization: Bearer pt_live_YOUR_KEY"Every response is JSON with a data field. List endpoints add a pagination object. Errors come back as { "error": { "code", "message" } } with a matching HTTP status.
{
"data": [
{
"id": "6a1f…",
"location_id": "59f2…",
"type": "washer",
"label": "07",
"status": "out_of_service",
"status_reason": "Not draining",
"down_since": "2026-10-28T13:05:41.000Z",
"attention_since": null,
"priority": "normal"
}
],
"pagination": { "limit": 100, "offset": 0, "returned": 1, "total": 1 }
}3. Endpoints
| Endpoint | Returns |
|---|---|
GET/me | What this key can see |
GET/summary | Machine counts by status |
GET/locations | List locations |
GET/machines | List machines |
GET/machines/{id} | Get one machine |
GET/machines/{id}/history | Machine timeline |
GET/status-history | List status changes |
GET/logs | List maintenance logs |
GET/parts-requests | List parts requests |
GET/warranty-claims | List warranty claims |
GET/refund-requests | List refund requests |
GET/reminders | List reminders |
Full parameters and response shapes are in the interactive reference.
4. Filtering and paging
location_idandmachine_idnarrow any list.updated_sincereturns only rows changed at or after an ISO timestamp. Poll it every few minutes instead of downloading everything.limit(up to 500, default 100) andoffsetpage through long lists.
# Everything that changed in the last 15 minutes
curl "https://pockettrack.app/api/v1/status-history?updated_since=2026-10-31T14:00:00Z" \
-H "Authorization: Bearer pt_live_YOUR_KEY"5. Machine statuses
working: in service, nothing flagged.in_service_attention: in service, flagged for attention.attention_sincesays since when.awaiting_followup: down, waiting on parts or a technician.down_sinceis set.out_of_service: down.down_sinceis set.
6. Example: Google Sheets
No server needed. This Apps Script function fills a sheet with your machines.
// Google Sheets → Extensions → Apps Script. Paste, set your key, then
// put =POCKETTRACK_MACHINES() in a cell. Refreshes when the sheet recalculates.
const KEY = "pt_live_YOUR_KEY";
function POCKETTRACK_MACHINES() {
const res = UrlFetchApp.fetch("https://pockettrack.app/api/v1/machines?limit=500", {
headers: { Authorization: "Bearer " + KEY },
});
const rows = JSON.parse(res.getContentText()).data;
const header = ["Label", "Type", "Status", "Reason", "Down since", "Location"];
return [header].concat(rows.map(m => [
m.label, m.type, m.status, m.status_reason || "", m.down_since || "", m.location_id,
]));
}7. Limits and good manners
- 120 requests per minute per key. Over that you get HTTP 429; wait a minute and retry.
- All timestamps are UTC in ISO 8601. Convert to your location’s timezone for display.
- Keep keys out of browsers and shared spreadsheets. If one leaks, revoke it and create another.
- The API is versioned at
/v1. We add fields without notice and never remove or rename them within a version.
Questions, or need write access? contactpockettrack@gmail.com