Sentinel API overview
REST resources and the live event WebSocket.
All endpoints except sign-in require Authorization: Bearer <token>. Obtain a token from POST /api/auth/login and renew it with POST /api/auth/refresh.
| Area | Endpoints |
|---|---|
| Cameras | GET/POST /api/cameras, PATCH/DELETE /api/cameras/{id} |
| Events | GET /api/events, PATCH /api/events/{id} |
| Cases | GET/POST /api/cases, PUT/PATCH /api/cases/{id}, case notes |
| Face watchlist | GET/POST /api/watchlist, DELETE /api/watchlist/{id}; POST /api/face/enroll, POST /api/face/search |
| Vehicles (ANPR) | GET /api/vehicles, GET/POST /api/vehicles/watchlist |
| Persons | GET /api/persons |
| Recordings and evidence | GET /api/recordings, GET/POST /api/evidence |
| Reports | GET /api/reports, POST /api/reports/generate |
| Assistant | POST /api/llm/chat, GET /api/llm/models |
| System | GET /api/stats, GET /api/system/health, GET /api/system/diagnostics, GET /api/audit-logs, GET/PUT /api/settings |
| Streams | GET /api/mediamtx/paths/, POST /api/mediamtx/add |
Live events
Subscribe to WS /ws/events for a real-time feed of security events.
TOKEN=$(curl -s -X POST https://sentinel.example/api/auth/login \
-H 'Content-Type: application/json' \
-d '{"username":"operator","password":"<password>"}' | jq -r .data.token)
curl -s https://sentinel.example/api/cameras -H "Authorization: Bearer $TOKEN"