Class: Kentaa::Api::Clients::Users
- Inherits:
-
Base
- Object
- Base
- Kentaa::Api::Clients::Users
show all
- Defined in:
- lib/kentaa/api/clients/users.rb
Instance Attribute Summary
Attributes inherited from Base
#config
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Instance Method Details
#all(options = {}) ⇒ Object
7
8
9
10
|
# File 'lib/kentaa/api/clients/users.rb', line 7
def all(options = {})
users = Kentaa::Api::Resources::Users.new(config, options)
users.all
end
|
#create(attributes = {}, options = {}) ⇒ Object
22
23
24
25
|
# File 'lib/kentaa/api/clients/users.rb', line 22
def create(attributes = {}, options = {})
user = Kentaa::Api::Resources::Users.new(config, options)
user.create(attributes)
end
|
#get(id, options = {}) ⇒ Object
17
18
19
20
|
# File 'lib/kentaa/api/clients/users.rb', line 17
def get(id, options = {})
user = Kentaa::Api::Resources::User.new(config, options.merge(id: id))
user.load
end
|
#list(options = {}) ⇒ Object
12
13
14
15
|
# File 'lib/kentaa/api/clients/users.rb', line 12
def list(options = {})
users = Kentaa::Api::Resources::Users.new(config, options)
users.load
end
|
#update(id, attributes = {}, options = {}) ⇒ Object
27
28
29
30
|
# File 'lib/kentaa/api/clients/users.rb', line 27
def update(id, attributes = {}, options = {})
user = Kentaa::Api::Resources::User.new(config, options.merge(id: id))
user.save(attributes)
end
|