Class: Fireblocks::Configuration
- Inherits:
-
Object
- Object
- Fireblocks::Configuration
- Defined in:
- lib/fireblocks/configuration.rb
Overview
base_url is set to a default but can be configured
Constant Summary collapse
- Error =
Class.new(StandardError)
Instance Attribute Summary collapse
- #api_key ⇒ Object
-
#base_url ⇒ Object
Returns the value of attribute base_url.
- #private_key ⇒ Object
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
13 14 15 16 17 |
# File 'lib/fireblocks/configuration.rb', line 13 def initialize @api_key = nil @private_key = nil @base_url = 'https://api.fireblocks.io' end |
Instance Attribute Details
#api_key ⇒ Object
19 20 21 22 23 24 25 26 |
# File 'lib/fireblocks/configuration.rb', line 19 def api_key = 'Fireblocks api key not set. See Fireblocks documentation ' \ 'to get a hold of your api key' raise Error, unless @api_key @api_key end |
#base_url ⇒ Object
Returns the value of attribute base_url.
11 12 13 |
# File 'lib/fireblocks/configuration.rb', line 11 def base_url @base_url end |
#private_key ⇒ Object
28 29 30 31 32 33 34 35 |
# File 'lib/fireblocks/configuration.rb', line 28 def private_key = 'Fireblocks private key not set. See Fireblocks documentation ' \ 'to get a hold of your private key' raise Error, unless @private_key @private_key end |