Documentation
¶
Index ¶
- type DateRange
- type ErrorResponse
- type EventsResponse
- type Server
- func (s *Server) HandleEvents(w http.ResponseWriter, r *http.Request)
- func (s *Server) HandleExport(w http.ResponseWriter, r *http.Request)
- func (s *Server) HandleHealth(w http.ResponseWriter, r *http.Request)
- func (s *Server) HandleStats(w http.ResponseWriter, r *http.Request)
- func (s *Server) HandleStatus(w http.ResponseWriter, r *http.Request)
- func (s *Server) Start() error
- type StatsResponse
- type StatusResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ErrorResponse ¶
type ErrorResponse struct { Error string `json:"error"` Message string `json:"message"` StatusCode int `json:"status_code"` Details interface{} `json:"details,omitempty"` }
ErrorResponse represents an error response
type EventsResponse ¶
type EventsResponse struct { Events []models.EventOutput `json:"events"` Total int `json:"total"` Page int `json:"page"` PageSize int `json:"page_size"` TotalPages int `json:"total_pages"` }
EventsResponse represents the response for events endpoint
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server represents the API server
func (*Server) HandleEvents ¶
func (s *Server) HandleEvents(w http.ResponseWriter, r *http.Request)
func (*Server) HandleExport ¶
func (s *Server) HandleExport(w http.ResponseWriter, r *http.Request)
func (*Server) HandleHealth ¶
func (s *Server) HandleHealth(w http.ResponseWriter, r *http.Request)
func (*Server) HandleStats ¶
func (s *Server) HandleStats(w http.ResponseWriter, r *http.Request)
func (*Server) HandleStatus ¶
func (s *Server) HandleStatus(w http.ResponseWriter, r *http.Request)
type StatsResponse ¶
type StatsResponse struct { TotalEvents int `json:"total_events"` OperationCounts map[string]int `json:"operation_counts"` ProcessCounts map[string]int `json:"process_counts"` DateRange *DateRange `json:"date_range,omitempty"` }
StatsResponse represents the response for stats endpoint
type StatusResponse ¶
type StatusResponse struct { Status string `json:"status"` DatabaseStatus string `json:"database_status"` DatabaseError string `json:"database_error,omitempty"` CanSearch bool `json:"can_search"` Message string `json:"message"` Operations []string `json:"operations"` Directory string `json:"directory"` Timestamp string `json:"timestamp"` }
StatusResponse represents the system status
Click to show internal directories.
Click to hide internal directories.