Documentation ¶
Index ¶
- func EventSource(m mediator.Mediator, log *slog.Logger) http.HandlerFunc
- func KeepAlive(m mediator.Mediator)
- func New(ctx context.Context, serviceName string, mediator mediator.Mediator, ...) (chi.Router, error)
- func NewQueryDeviceHandler(m messagecollector.MeasurementRetriever, log *slog.Logger) http.HandlerFunc
- func NewQueryMeasurementsHandler(m messagecollector.MeasurementRetriever, log *slog.Logger) http.HandlerFunc
- type ApiResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EventSource ¶
func NewQueryDeviceHandler ¶
func NewQueryDeviceHandler(m messagecollector.MeasurementRetriever, log *slog.Logger) http.HandlerFunc
func NewQueryMeasurementsHandler ¶
func NewQueryMeasurementsHandler(m messagecollector.MeasurementRetriever, log *slog.Logger) http.HandlerFunc
Types ¶
type ApiResponse ¶
type ApiResponse struct { Meta *meta `json:"meta,omitempty"` Data any `json:"data"` Links *links `json:"links,omitempty"` }
func NewApiResponse ¶
func NewApiResponse(r *http.Request, data any, count, total, offset, limit uint64) ApiResponse
func (ApiResponse) Byte ¶
func (r ApiResponse) Byte() []byte
Click to show internal directories.
Click to hide internal directories.