Class: Amara::Client

Inherits:
API
  • Object
show all
Defined in:
lib/amara/client.rb

Constant Summary

Constants included from Connection

Amara::Connection::ALLOWED_OPTIONS

Instance Attribute Summary

Attributes inherited from API

#current_options

Instance Method Summary collapse

Methods inherited from API

#apply_options, #args_to_options, #base_path, #check_for_error, #create, #create!, #delete, #delete!, #force_raise_errors, #get, #get!, #initialize, #list, #list!, #paginate, #request, #update, #update!

Methods included from Connection

#connection, #merge_default_options

Constructor Details

This class inherits a constructor from Amara::API

Instance Method Details

#activity(params = {}, &block) ⇒ Object



6
7
8
# File 'lib/amara/client.rb', line 6

def activity(params={}, &block)
  @activity ||= ApiFactory.api('Amara::Activity', self, params, &block)
end

#languages(params = {}, &block) ⇒ Object



10
11
12
# File 'lib/amara/client.rb', line 10

def languages(params={}, &block)
  @languages ||= ApiFactory.api('Amara::Languages', self, params, &block)
end

#message(params = {}, &block) ⇒ Object



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

def message(params={}, &block)
  @message ||= ApiFactory.api('Amara::Message', self, params, &block)
end

#path(path, params = {}, &block) ⇒ Object



30
31
32
33
34
# File 'lib/amara/client.rb', line 30

def path(path, params={}, &block)
  @path ||= ApiFactory.api('Amara::Path', self, params, &block)
  @path.current_options['path'] = path
  @path
end

#teams(params = {}, &block) ⇒ Object



18
19
20
# File 'lib/amara/client.rb', line 18

def teams(params={}, &block)
  @teams ||= ApiFactory.api('Amara::Teams', self, params, &block)
end

#users(params = {}, &block) ⇒ Object



26
27
28
# File 'lib/amara/client.rb', line 26

def users(params={}, &block)
  @users ||= ApiFactory.api('Amara::Users', self, params, &block)
end

#videos(params = {}, &block) ⇒ Object



22
23
24
# File 'lib/amara/client.rb', line 22

def videos(params={}, &block)
  @videos ||= ApiFactory.api('Amara::Videos', self, params, &block)
end