Categorygithub.com/Kviky/errors
modulepackage
1.0.21
Repository: https://github.com/kviky/errors.git
Documentation: pkg.go.dev

# README

Ahoylog errors package

Ahoylog package used together with go-swagger to produce standardized set of errors as ProblemDetails.

List of errors

HTTP 400

TitleDetailStatusCodeInstance
AlreadyExistsThe requested resource already exists!400badRequestclient
BadRequestThere was a problem with the request!400badRequestclient
CharterHasListingsCharter cannot be deleted, because it still has some active listings!400badRequestclient
CharterNotCreatedThere was a problem to create charter profile!400badRequestclient
FileExistsAlreadyThe requested resource already exists!400badRequestclient
FileNotCreatedThere was a problem to create file!400badRequestexport
InvalidBodyParamThe HTTP request contains an unsupported body parameter!400badRequestclient
InvalidDatesThe requested dates are invalid!400badRequestclient
InvalidHeaderParamThe HTTP request contains an unsupported header parameter!400badRequestclient
InvalidMsgFormatThe HTTP request has an invalid format!400badRequestclient
ImageInvalidFile must be a valid image - image/jpeg, image/jpg, image/png!400badRequestclient
ImageNotDeletedThere was a problem to delete image!400badRequestimage
ImageNotUploadedThere was a problem to upload image!400badRequestimage
InactiveListingListing %v is not in the active state!400badRequestclient
InvalidOwnerListingCharter doesn't own the listing %v!400badRequestclient
InvalidQueryParamThe HTTP request contains an unsupported query parameter in the URI!400badRequestclient
InvalidPathParamThe HTTP request contains an unsupported path parameter in the URI!400badRequestclient
ListingNotCreatedThere was a problem to create listing!400badRequestclient
LocationNotCreatedThere was a problem to create location!400badRequestclient
MandatoryParamIncorrectMandatory parameter has semantically incorrect value!400badRequestclient
MandatoryParamMissingParameter which is defined as mandatory is missing!400badRequestclient
NameAlreadyTakenRequested name is already taken! Please, specify another name.400badRequestclient
OffersEndedAvailable number of the offers ended for today!400badRequestclient
OffersMaxListingsMaximum limit of %v listings is reached. Please, reduce number of listings in offer!400badRequestclient
PortAlreadyExistsRequested port/marina name already exists for this country and city!400badRequestclient
ReservationNotCreatedThere was a problem to create reservation!400badRequestclient

HTTP 401

TitleDetailStatusCodeInstance
InvalidAuthTokenAuthorization token is invalid!401unauthorizedclient
MissingAuthTokenAuthorization token is missing!401unauthorizedclient
UnauthorizedAccessThe request doesn't have permissions to access resources!401unauthorizedapi

HTTP 403

TitleDetailStatusCodeInstance
ForbiddenActionYou don't have a permission to make this action!403forbiddenclient
ForbiddenResourceYou don't have a permission to access this resource!403forbiddenclient
ForbiddenUploadThis accound doesn't have permission to upload images!403forbiddenclient

HTTP 404

TitleDetailStatusCodeInstance
CharterNotFoundThe charter indicated in the request does not exist!404notFoundclient
ListingNotFoundThe listing indicated in the request does not exist!404notFoundclient
LocationNotFoundThe location indicated in the request does not exist!404notFoundclient
ReservationNotFoundRequested reservation does not exist!404notFoundclient
ResourceNotFoundRequested resource does not exist!404notFoundclient
UserNotFoundThe user indicated in the request does not exist!404notFoundclient
UsersNotFoundRequested users does not exist!404notFoundclient

HTTP 405

TitleDetailStatusCodeInstance
MethodNotAllowedRequested method is not allowed. Check the response header Allow for allowed methods!405methodNotAllowedclient

HTTP 429

TitleDetailStatusCodeInstance
CongestionRiskThe request is rejected due to excessive traffic. If continued over time, may lead to an overload situation.429tooManyRequestsclient

HTTP 500

TitleDetailStatusCodeInstance
UnspecifiedFailureThe request is rejected due to unspecified reason at the system!500internalServerErrorapi
SystemFailureWe are sorry, but there is an internal problem with the application!500internalServerErrorapi

HTTP 503

TitleDetailStatusCodeInstance
ServiceUnavailableThe service experiences congestion and performs overload control. It does not allow the request to be processed.503serviceUnavailableapi

HTTP 504

TitleDetailStatusCodeInstance
GatewayTimeoutThe request is rejected due a request that has timed out at the HTTP client.504gatewayTimeoutapi

# Packages

No description provided by the author

# Functions

CreateProblemDetails - Helper function to create ProblemDetails object.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ServeError the error handler interface implementation.

# Constants

List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
list of 404 errors.
list of 429 errors.
List of 400 errors.
List of 400 errors.
List of 403 errors.
List of 403 errors.
List of 403 errors.
List of 504 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
Types of instances.
Types of instances.
Types of instances.
Types of instances.
Types of instances.
Types of instances.
Types of instances.
List of 401 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
list of 404 errors.
List of 400 errors.
list of 404 errors.
List of 400 errors.
List of 400 errors.
list of 405 errors.
List of 401 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
List of 400 errors.
list of 404 errors.
list of 404 errors.
List of 503 errors.
List of 500 errors.
List of 401 errors.
List of 500 errors.
list of 404 errors.
list of 404 errors.