Module: Recurly::Errors

Defined in:
lib/recurly/errors.rb,
lib/recurly/errors/api_errors.rb,
lib/recurly/errors/network_errors.rb

Defined Under Namespace

Classes: APIError, BadGatewayError, BadRequestError, ClientError, ConnectionFailedError, ForbiddenError, ImmutableSubscriptionError, InternalServerError, InvalidApiKeyError, InvalidApiVersionError, InvalidContentTypeError, InvalidPermissionsError, InvalidResponseError, InvalidTokenError, MissingFeatureError, NetworkError, NotAcceptableError, NotFoundError, NotModifiedError, PaymentRequiredError, PreconditionFailedError, RateLimitedError, RedirectionError, ResponseError, SSLError, ServerError, ServiceNotAvailableError, ServiceUnavailableError, SimultaneousRequestError, TimeoutError, TooManyRequestsError, TransactionError, UnauthorizedError, UnavailableError, UnavailableInApiVersionError, UnknownApiVersionError, UnprocessableEntityError, ValidationError

Constant Summary collapse

ERROR_MAP =
{
  "500" => "InternalServerError",
  "502" => "BadGatewayError",
  "503" => "ServiceUnavailableError",
  "304" => "NotModifiedError",
  "400" => "BadRequestError",
  "401" => "UnauthorizedError",
  "402" => "PaymentRequiredError",
  "403" => "ForbiddenError",
  "404" => "NotFoundError",
  "406" => "NotAcceptableError",
  "412" => "PreconditionFailedError",
  "422" => "UnprocessableEntityError",
  "429" => "TooManyRequestsError",
}