Files
zeekay 4532862f22 fix: use query-param format for crypto bars (sandbox single path 404s)
Same issue as snapshots — Alpaca sandbox returns 404 for
/v1beta3/crypto/us/{sym}/bars but works with
/v1beta3/crypto/us/bars?symbols={sym}. Also handle the wrapped
response format {"bars":{"BTC/USD":[...]}} vs stock {"bars":[...]}.
2025-12-24 00:57:08 -07:00

17 lines
447 B
Go

package compliance
import "net/http"
// dashboardHandler holds dashboard HTTP handler state.
type dashboardHandler struct {
store ComplianceStore
}
func (h *dashboardHandler) handleDashboard(w http.ResponseWriter, r *http.Request) {
writeJSON(w, http.StatusOK, h.store.ComputeDashboard())
}
func (h *dashboardHandler) handleESignDashboard(w http.ResponseWriter, r *http.Request) {
writeJSON(w, http.StatusOK, h.store.ComputeESignStats())
}