API Overview
Endpoints0
Auth Methods0Session, Bearer, Device Token
FormatJSON
ProtocolHTTPS
RESTful API Reference
The NexaIoT exposes REST endpoints organized into three categories: Device Ingestion (token auth), Dashboard APIs (session auth), and Mobile APIs (Bearer token auth).
Endpoint Index
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /api/telemetry/ingest | Device Token | Ingest telemetry data |
| POST | /api/heartbeat | Device Token | Device heartbeat |
| GET | /api/devices/latest | Session/Bearer | Latest device metrics |
| GET | /api/alerts-feed | Session | Alert feed for dashboard |
| GET | /api/incidents-feed | Session | Incident feed |
| POST | /api/alert-action | Session | Acknowledge/resolve alert |
| POST | /api/incident-action | Session | Incident actions |
| POST | /api/mobile/login | None | Mobile login, returns token |
| GET | /api/mobile/devices | Bearer | Devices for org |
| GET | /api/mobile/alerts | Bearer | Alerts for org |
📡 Response Envelope
// All API responses use this format:
{ "status": "ok", "data": { ... } }
{ "status": "error", "message": "...", "code": 401 }
🛠️ Developer Quick Start
1. Register an account and create an organization. 2. Add a device via the dashboard — copy the 64-char device token. 3. Send a POST to /api/telemetry/ingest with the token. 4. Watch the dashboard update in real time. 5. For mobile apps, call /api/mobile/login to get a Bearer token.