Class: Infusionsoft::Api::Client
- Inherits:
-
Object
- Object
- Infusionsoft::Api::Client
- Includes:
- Helpers
- Defined in:
- lib/infusionsoft/api/client.rb
Instance Attribute Summary collapse
-
#api_key ⇒ Object
readonly
Returns the value of attribute api_key.
-
#app_name ⇒ Object
readonly
Returns the value of attribute app_name.
Instance Method Summary collapse
- #connection ⇒ Object
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
Methods included from Helpers
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
10 11 12 13 14 15 16 17 18 |
# File 'lib/infusionsoft/api/client.rb', line 10 def initialize() model :Contact model :ContactGroup model :ContactGroupAssign model :ContactGroupCategory @api_key = [:api_key] @app_name = [:app_name] end |
Instance Attribute Details
#api_key ⇒ Object (readonly)
Returns the value of attribute api_key.
8 9 10 |
# File 'lib/infusionsoft/api/client.rb', line 8 def api_key @api_key end |
#app_name ⇒ Object (readonly)
Returns the value of attribute app_name.
8 9 10 |
# File 'lib/infusionsoft/api/client.rb', line 8 def app_name @app_name end |
Instance Method Details
#connection ⇒ Object
20 21 22 |
# File 'lib/infusionsoft/api/client.rb', line 20 def connection @client ||= XMLRPC::Client.new2("https://#{@app_name}.infusionsoft.com:443/api/xmlrpc") end |