Documentation ¶
Index ¶
- Variables
- func BadRequest(c *fiber.Ctx) error
- func BadRequestWithErrors(c *fiber.Ctx, innerErrors []error) error
- func Created(c *fiber.Ctx, data interface{}) error
- func Error(c *fiber.Ctx, statusCode int, err error) error
- func ErrorWithDetails(c *fiber.Ctx, statusCode int, errorMesage error, errs []error) error
- func Forbiden(c *fiber.Ctx) error
- func InternalServerError(c *fiber.Ctx) error
- func NotFound(c *fiber.Ctx) error
- func OK(c *fiber.Ctx, data interface{}) error
- func Success(c *fiber.Ctx, statusCode int, data interface{}) error
- func UnprocessableEntity(c *fiber.Ctx) error
- type Response
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrBadRequest = errors.New("the server could not understand the request due to invalid syntax or missing parameters") ErrForbiden = errors.New("the server understood the request, but it refuses to authorize it. The client does not have the necessary permissions") ErrInternalServerError = errors.New("an unexpected error occurred on the server. Please try again later") ErrUnprocessableEntity = errors.New("the server understands the request, but it cannot process the provided data due to semantic errors") ErrNotFound = errors.New("the requested resource could not be found on the server") )
Functions ¶
func BadRequest ¶
func BadRequest(c *fiber.Ctx) error
func BadRequestWithErrors ¶
func ErrorWithDetails ¶
func InternalServerError ¶
func InternalServerError(c *fiber.Ctx) error
func UnprocessableEntity ¶
func UnprocessableEntity(c *fiber.Ctx) error
Types ¶
Click to show internal directories.
Click to hide internal directories.