First release of open core

This commit is contained in:
t
2026-04-02 10:57:36 -04:00
parent 1c94f12d1c
commit 084c1321fc
101 changed files with 8812 additions and 17 deletions

View File

@@ -0,0 +1,17 @@
package analytics
import (
"encoding/json"
"net/http"
)
func (h *Handler) HandleGetAnalyticsSummary(w http.ResponseWriter, r *http.Request) {
summary, err := h.Store.GetAnalyticsSummary(r.Context())
if err != nil {
http.Error(w, "Failed to generate analytics", http.StatusInternalServerError)
return
}
w.Header().Set("Content-Type", "application/json")
json.NewEncoder(w).Encode(summary)
}