Documentation
¶
Index ¶
- func Delete(router *chi.Mux, pattern string, handler Handler, ...)
- func Get(router *chi.Mux, pattern string, handler Handler, ...)
- func Patch(router *chi.Mux, pattern string, handler Handler, ...)
- func Post(router *chi.Mux, pattern string, handler Handler, ...)
- func Put(router *chi.Mux, pattern string, handler Handler, ...)
- type ErrorResponse
- type Handler
- type MessageResponse
- type Response
- func BadRequest(body any) Response
- func Conflict(body any) Response
- func Created(body any) Response
- func Forbidden(body any) Response
- func InternalServerError() Response
- func MethodNotAllowed() Response
- func NoContent() Response
- func NotFound(body any) Response
- func OK(body any) Response
- func Unauthorized(body any) Response
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ErrorResponse ¶
type ErrorResponse struct {
Error any `json:"error"`
}
type MessageResponse ¶
type MessageResponse struct {
Message string `json:"message"`
}
type Response ¶
func BadRequest ¶
func InternalServerError ¶
func InternalServerError() Response
func MethodNotAllowed ¶
func MethodNotAllowed() Response
func Unauthorized ¶
Click to show internal directories.
Click to hide internal directories.