MCPcopy
hub / github.com/control-theory/gonzo / handlePatterns

Method handlePatterns

internal/web/api.go:58–66  ·  view source on GitHub ↗
(w http.ResponseWriter, r *http.Request)

Source from the content-addressed store, hash-verified

56}
57
58func (s *Server) handlePatterns(w http.ResponseWriter, r *http.Request) {
59 filters := parseFilters(r)
60 data, err := s.engine.QueryPatterns(r.Context(), filters)
61 if err != nil {
62 writeError(w, http.StatusInternalServerError, err.Error())
63 return
64 }
65 writeJSON(w, data)
66}
67
68func (s *Server) handleClasses(w http.ResponseWriter, r *http.Request) {
69 filters := parseFilters(r)

Callers

nothing calls this directly

Calls 4

parseFiltersFunction · 0.85
writeErrorFunction · 0.85
writeJSONFunction · 0.85
QueryPatternsMethod · 0.80

Tested by

no test coverage detected