Class: ShopsavvyDataApi::Configuration
- Inherits:
-
Object
- Object
- ShopsavvyDataApi::Configuration
- Defined in:
- lib/shopsavvy_data_api/models.rb
Overview
Configuration for ShopSavvy Data API client
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#base_url ⇒ Object
Returns the value of attribute base_url.
-
#timeout ⇒ Object
Returns the value of attribute timeout.
Instance Method Summary collapse
-
#initialize(api_key:, base_url: "https://api.shopsavvy.com/v1", timeout: 30) ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize(api_key:, base_url: "https://api.shopsavvy.com/v1", timeout: 30) ⇒ Configuration
Returns a new instance of Configuration.
8 9 10 11 12 13 14 |
# File 'lib/shopsavvy_data_api/models.rb', line 8 def initialize(api_key:, base_url: "https://api.shopsavvy.com/v1", timeout: 30) @api_key = api_key @base_url = base_url @timeout = timeout validate_api_key! end |
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key.
6 7 8 |
# File 'lib/shopsavvy_data_api/models.rb', line 6 def api_key @api_key end |
#base_url ⇒ Object
Returns the value of attribute base_url.
6 7 8 |
# File 'lib/shopsavvy_data_api/models.rb', line 6 def base_url @base_url end |
#timeout ⇒ Object
Returns the value of attribute timeout.
6 7 8 |
# File 'lib/shopsavvy_data_api/models.rb', line 6 def timeout @timeout end |