# API Reference — Device Location All endpoints accept and return JSON. Base URL in local development: `http://localhost:5000`. --- ## `GET /devices` Retrieve data from `/devices`. ### Request ```json { "example": "see source code for full schema" } ``` ### Response `200` ```json { "status": "ok" } ``` ### Try it ```bash curl http://localhost:5000/devices ``` --- ## `GET /locations` Retrieve data from `/locations`. ### Request ```json { "example": "see source code for full schema" } ``` ### Response `200` ```json { "status": "ok" } ``` ### Try it ```bash curl http://localhost:5000/locations ``` --- ## `GET /{simCardId}/location` Retrieve data from `/{simCardId}/location`. ### Request ```json { "example": "see source code for full schema" } ``` ### Response `200` ```json { "status": "ok" } ``` ### Try it ```bash curl http://localhost:5000/{simCardId}/location ``` --- ## Error Handling All endpoints return JSON. On error: ```json {"error": "Description of what went wrong"} ``` | Status | Meaning | |--------|---------| | `200` | Success | | `400` | Bad request — missing or invalid fields | | `401` | Invalid API key or webhook signature | | `429` | Rate limit exceeded | | `500` | Server error | | `503` | Upstream network error talking to Telnyx |