Documentation
¶
Index ¶
- func Error(c echo.Context, message string) error
- func ErrorResponse(c echo.Context, statusCode int, message string) error
- func NotFound(c echo.Context) error
- func ServerError(c echo.Context) error
- func Success(c echo.Context, data any) error
- func WebErrorResponse(c echo.Context, renderer view.Renderer, statusCode int, message string) error
- type APIResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ErrorResponse ¶ added in v0.1.5
ErrorResponse sends an error response with a custom status code
func ServerError ¶ added in v0.2.0
func ServerError(c echo.Context) error
ServerError renders a 500 error page
Types ¶
type APIResponse ¶ added in v0.1.5
type APIResponse struct { Success bool `json:"success"` Message string `json:"message,omitempty"` Data any `json:"data,omitempty"` }
APIResponse represents a standardized API response structure
Click to show internal directories.
Click to hide internal directories.