Documentation
¶
Index ¶
Constants ¶
View Source
const LogType = "response"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataResponse ¶
type DataResponse struct {
Data any `json:"data"`
}
func NewDataResponse ¶
func NewDataResponse(data any) DataResponse
type ErrorResponse ¶
type ErrorResponse struct {
Error error `json:"error"`
}
func NewErrorResponse ¶
func NewErrorResponse(err error) ErrorResponse
type LoggableData ¶ added in v0.0.4
type LoggableData struct { Date time.Time `json:"date"` ReqID string `json:"requestID,omitempty"` Type string `json:"type"` DataResponse }
func (*LoggableData) RequestID ¶ added in v0.0.4
func (r *LoggableData) RequestID() string
func (*LoggableData) SetRequestID ¶ added in v0.0.4
func (r *LoggableData) SetRequestID(id string)
Click to show internal directories.
Click to hide internal directories.