Class: Polar::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/polar/configuration.rb

Constant Summary collapse

PRODUCTION_SERVER =

Server environments

'https://api.polar.sh/v1'
SANDBOX_SERVER =
'https://sandbox-api.polar.sh/v1'

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



11
12
13
14
15
16
17
# File 'lib/polar/configuration.rb', line 11

def initialize
  @server = :production
  @timeout = 30
  @retries = 3
  @debug = false
  @logger = nil
end

Instance Attribute Details

#access_tokenObject

Returns the value of attribute access_token.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def access_token
  @access_token
end

#base_urlObject

Returns the value of attribute base_url.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def base_url
  @base_url
end

#debugObject

Returns the value of attribute debug.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def debug
  @debug
end

#loggerObject

Returns the value of attribute logger.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def logger
  @logger
end

#retriesObject

Returns the value of attribute retries.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def retries
  @retries
end

#serverObject

Returns the value of attribute server.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def server
  @server
end

#timeoutObject

Returns the value of attribute timeout.



5
6
7
# File 'lib/polar/configuration.rb', line 5

def timeout
  @timeout
end