Sha256: ff1f37f382ed8a79442c8573fd7ac7f7c5a8eea0f35b47dfd5699286e7170b76

Contents?: true

Size: 1.6 KB

Versions: 4

Compression:

Stored size: 1.6 KB

Contents

module HelloSign
  module Error
    # Custom error class for rescuing from all HelloSign errors.
    class Error < StandardError; end

    # Raise when attributes are missing.
    class MissingAttributes < Error; end

    # Raised when API endpoint credentials not configured.
    class MissingCredentials < Error; end

    # Raised when impossible to parse response body.
    class Parsing < Error; end

    # Raised when API endpoint returns the HTTP status code 400.
    class BadRequest < Error; end

    # Raised when API endpoint returns the HTTP status code 401.
    class Unauthorized < Error; end

    # Raised when API endpoint returns the HTTP status code 402.
    class PaidApiPlanRequired < Error; end

    # Raised when API endpoint returns the HTTP status code 403.
    class Forbidden < Error; end

    # Raised when API endpoint returns the HTTP status code 404.
    class NotFound < Error; end

    # Raised when API endpoint returns the HTTP status code 405.
    class MethodNotAllowed < Error; end

    # Raised when API endpoint returns the HTTP status code 409.
    class Conflict < Error; end

    # Raised when API endpoint returns the HTTP status code 410.
    class Gone < Error; end

    # Raised when API endpoint returns the HTTP status code 500.
    class InternalServerError < Error; end

    # Raised when API endpoint returns the HTTP status code 502.
    class BadGateway < Error; end

    # Raised when API endpoint returns the HTTP status code 503.
    class ServiceUnavailable < Error; end

    # Raised when API endpoint returns the HTTP status code 503.
    class NotSupportedType < Error; end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
hellosign-ruby-sdk-3.0.11 lib/hello_sign/error.rb
hellosign-ruby-sdk-3.0.10 lib/hello_sign/error.rb
hellosign-ruby-sdk-3.0.9 lib/hello_sign/error.rb
hellosign-ruby-sdk-3.0.7 lib/hello_sign/error.rb