package
0.0.0-20201206181251-5ae7496d79a3
Repository: https://github.com/byteball/odex-backend.git
Documentation: pkg.go.dev

# Functions

InternalServerError creates a new API error representing an internal server error (HTTP 500).
InvalidData converts a data validation error into an API error (HTTP 400).
LoadMessages reads a YAML file containing error templates.
NewHTTPError creates a new APIError with the given HTTP status code, error code, and parameters for replacing placeholders in the error template.
NotFound creates a new API error representing a resource-not-found error (HTTP 404).
Unauthorized creates a new API error representing an authentication failure (HTTP 401).

# Structs

APIError represents an error that can be sent in an error response.

# Type aliases

No description provided by the author