Skip to main content
For TypeScript projects, use CameraManager instead of calling these endpoints directly — it manages the binary lifecycle, camera connections, and SSE events automatically.

Server Status

method
GET
GET /api/server/status
Health check endpoint. Returns server version, uptime, platform, and camera counts. Used by ServerManager and CameraManager to confirm the server is ready.
curl http://localhost:8080/api/server/status

Server Logs

method
GET
GET /api/server/logs
Returns buffered server log output. Useful for debugging without terminal access.
lines
integer
default:"100"
Number of recent log lines
level
string
default:"info"
debug, info, warn, or error
curl http://localhost:8080/api/server/logs

Shutdown

method
POST
POST /api/server/shutdown
Initiates graceful shutdown: disconnects all cameras, closes SSE/WebSocket connections, then exits. CameraManager.close() and ServerManager.stop() call this before falling back to SIGTERM.
curl -X POST http://localhost:8080/api/server/shutdown
{
  "success": true,
  "message": "Shutdown initiated"
}