Class: Cryptopay::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/cryptopay/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize {|_self| ... } ⇒ Config

Returns a new instance of Config.

Yields:

  • (_self)

Yield Parameters:



23
24
25
26
27
# File 'lib/cryptopay/config.rb', line 23

def initialize
  yield(self)

  validate!
end

Instance Attribute Details

#api_keyObject

Cryptopay API Key



9
10
11
# File 'lib/cryptopay/config.rb', line 9

def api_key
  @api_key
end

#api_secretObject

Cryptopay API Secret



12
13
14
# File 'lib/cryptopay/config.rb', line 12

def api_secret
  @api_secret
end

#api_urlObject

Cryptopay API Base URL



6
7
8
# File 'lib/cryptopay/config.rb', line 6

def api_url
  @api_url
end

#callback_secretObject

Cryptopay callback secret



15
16
17
# File 'lib/cryptopay/config.rb', line 15

def callback_secret
  @callback_secret
end

#faraday_adapterObject

The Faraday adapter to be used. Net::HTTP by default



21
22
23
# File 'lib/cryptopay/config.rb', line 21

def faraday_adapter
  @faraday_adapter
end

#faraday_builderObject

Optional proc yeilding the Faraday builder



18
19
20
# File 'lib/cryptopay/config.rb', line 18

def faraday_builder
  @faraday_builder
end