Class: Unisender::API

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_key, locale = 'en', test = false) ⇒ API

Returns a new instance of API.



16
17
18
19
20
21
22
23
# File 'lib/unisender_api.rb', line 16

def initialize(api_key, locale = 'en', test = false)
  self.api = ApiCall.new(api_key, locale, test)
  @lists = Lists.new(self.api)
  @messages = Messages.new(self.api)
  @statistics = Statistics.new(self.api)
  @extends = Extends.new(self.api)
  @partners = Partners.new(self.api)
end

Instance Attribute Details

#apiObject

Returns the value of attribute api.



14
15
16
# File 'lib/unisender_api.rb', line 14

def api
  @api
end

#extendsObject

Returns the value of attribute extends.



14
15
16
# File 'lib/unisender_api.rb', line 14

def extends
  @extends
end

#listsObject

Returns the value of attribute lists.



14
15
16
# File 'lib/unisender_api.rb', line 14

def lists
  @lists
end

#messagesObject

Returns the value of attribute messages.



14
15
16
# File 'lib/unisender_api.rb', line 14

def messages
  @messages
end

#partnersObject

Returns the value of attribute partners.



14
15
16
# File 'lib/unisender_api.rb', line 14

def partners
  @partners
end

#statisticsObject

Returns the value of attribute statistics.



14
15
16
# File 'lib/unisender_api.rb', line 14

def statistics
  @statistics
end