Add minimal dashboard page served at /
Single embedded HTML page that reads the daily summary and activities endpoints with a user-supplied API key: goals, totals by kind, top labels and a timeline for the selected day. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -14,6 +14,7 @@ import (
|
||||
"ccp/internal/ingest"
|
||||
"ccp/internal/store"
|
||||
"ccp/internal/summary"
|
||||
"ccp/internal/web"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -36,6 +37,7 @@ func New(s *store.Store, loc *time.Location, log *slog.Logger) http.Handler {
|
||||
writeJSON(w, http.StatusOK, map[string]string{"status": "ok"})
|
||||
})
|
||||
mux.HandleFunc("GET /readyz", srv.ready)
|
||||
mux.HandleFunc("GET /{$}", web.Handler)
|
||||
|
||||
api := http.NewServeMux()
|
||||
api.HandleFunc("POST /desktop/events", srv.ingestEvents(ingest.Desktop))
|
||||
|
||||
Reference in New Issue
Block a user