Dashboard API
Real-time dashboard endpoints power the Limon operations console. Provide SSE streaming, WebSocket chat, and agent session management.
Overview
The dashboard API serves the Limon Vue.js 3 frontend. It provides real-time streaming via SSE for operational views (events, goals, workers), WebSocket for chat, and REST for CRUD operations on all resources.
Authentication
Requires Authorization: Bearer <token> or zerg_session cookie. Dashboard views require admin role for operational panels.
Endpoints
SSE Event Stream
GET /api/v1/events/streamSSE stream for real-time event display. Events include goal lifecycle, worker status changes, and system events.
event: goal.step_completed
data: {"goal_id": "goal-abc123", "step": 3, "result": "..."}
event: worker.status
data: {"worker_id": "w-001", "status": "idle"}Worker Status
GET /api/v1/workers/bgReturns background worker status for the dashboard:
{
"ok": true,
"tasks": [
{
"id": "bg-001",
"status": "running",
"agent_id": "agent-xyz",
"task_type": "research",
"progress": "Step 2/5",
"started_at": 1745600000
}
]
}Provider Dashboard
GET /api/v1/providers/healthAggregated provider health for the dashboard panel:
{
"ok": true,
"providers": [
{
"name": "anthropic",
"status": "healthy",
"latency_p50": 1200,
"latency_p99": 4500,
"requests_1h": 342,
"circuit_breaker": "closed"
}
]
}Memory Dashboard
GET /api/v1/memory/statsMemory usage statistics across agents:
{
"ok": true,
"total_entries": 15234,
"agents": 8,
"storage": { "ets": "1.2 MB", "pgvector": "4.5 MB" }
}Goals Dashboard
GET /api/v1/goalsAggregated goal metrics for the dashboard:
{
"ok": true,
"active": 5,
"completed_today": 12,
"failed_today": 1,
"avg_steps": 4.2,
"avg_duration_seconds": 180
}Dashboard Auto-Refresh:
Limon views use polling-based refresh (usePolling) that calls refresh() immediately on mount. SSE supplements polling for real-time updates.
Error Codes:
| Code | Description |
|---|---|
| 401 | Authentication required |
| 403 | Admin role required for operational views |
Examples:
curl -N http://127.0.0.1:11434/api/v1/events/stream \
-H "Authorization: Bearer $TOKEN"
curl http://127.0.0.1:11434/api/v1/goals \
-H "Authorization: Bearer $TOKEN"
curl http://127.0.0.1:11434/api/v1/providers/health \
-H "Authorization: Bearer $TOKEN"