Class: Kasabi::Attribution
- Inherits:
-
BaseClient
- Object
- BaseClient
- Kasabi::Attribution
- Defined in:
- lib/kasabi/api/attribution.rb
Instance Attribute Summary
Attributes inherited from BaseClient
Instance Method Summary collapse
- #get_attribution ⇒ Object
-
#initialize(endpoint, options = {}) ⇒ Attribution
constructor
Initialize the attribution client to work with a specific endpoint.
Methods inherited from BaseClient
#client_options, #get, #post, #validate_response
Constructor Details
#initialize(endpoint, options = {}) ⇒ Attribution
Initialize the attribution client to work with a specific endpoint
The options hash can contain the following values:
-
:apikey: required. apikey authorized to use the API
-
:client: HTTPClient object instance
10 11 12 |
# File 'lib/kasabi/api/attribution.rb', line 10 def initialize(endpoint, ={}) super(endpoint, ) end |
Instance Method Details
#get_attribution ⇒ Object
14 15 16 17 18 |
# File 'lib/kasabi/api/attribution.rb', line 14 def get_attribution() response = get(@endpoint) validate_response(response) return JSON.parse( response.content ) end |