Class: ZohoSign::BaseService

Inherits:
ActiveCall::Base
  • Object
show all
Includes:
ActiveCall::Api
Defined in:
lib/zoho_sign/base_service.rb

Constant Summary collapse

CACHE_KEY =
{ access_token: 'zoho_sign/base_service/access_token' }.freeze

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#access_tokenObject (readonly)

Returns the value of attribute access_token.



18
19
20
# File 'lib/zoho_sign/base_service.rb', line 18

def access_token
  @access_token
end

#facadeObject (readonly)

Returns the value of attribute facade.



18
19
20
# File 'lib/zoho_sign/base_service.rb', line 18

def facade
  @facade
end

Class Method Details

.exception_mappingObject



29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# File 'lib/zoho_sign/base_service.rb', line 29

def exception_mapping
  {
    validation_error:              ZohoSign::ValidationError,
    request_error:                 ZohoSign::RequestError,
    client_error:                  ZohoSign::ClientError,
    server_error:                  ZohoSign::ServerError,
    bad_request:                   ZohoSign::BadRequestError,
    unauthorized:                  ZohoSign::UnauthorizedError,
    forbidden:                     ZohoSign::ForbiddenError,
    not_found:                     ZohoSign::NotFoundError,
    not_acceptable:                ZohoSign::NotAcceptableError,
    proxy_authentication_required: ZohoSign::ProxyAuthenticationRequiredError,
    request_timeout:               ZohoSign::RequestTimeoutError,
    conflict:                      ZohoSign::ConflictError,
    gone:                          ZohoSign::GoneError,
    unprocessable_entity:          ZohoSign::UnprocessableEntityError,
    too_many_requests:             ZohoSign::TooManyRequestsError,
    internal_server_error:         ZohoSign::InternalServerError,
    not_implemented:               ZohoSign::NotImplementedError,
    bad_gateway:                   ZohoSign::BadGatewayError,
    service_unavailable:           ZohoSign::ServiceUnavailableError,
    gateway_timeout:               ZohoSign::GatewayTimeoutError
  }.freeze
end