Module: Fleetly::User
- Included in:
- Client
- Defined in:
- lib/fleetly/user.rb
Instance Method Summary collapse
-
#me(options = {}) ⇒ Hashie::Mash
Retrieve information about ‘me` associated to the `oauth_token`.
-
#user_search(options = {}) ⇒ Hashie::Mash
Retrieve users base on search params associated to the ‘oauth_token`.
Instance Method Details
#me(options = {}) ⇒ Hashie::Mash
Retrieve information about ‘me` associated to the `oauth_token`
15 16 17 18 19 20 |
# File 'lib/fleetly/user.rb', line 15 def me(={}) [:oauth_token] = token user_me_response = get('/api/v1/users/me', ) user_me_response if user_me_response.result? end |
#user_search(options = {}) ⇒ Hashie::Mash
Retrieve users base on search params associated to the ‘oauth_token`
32 33 34 35 36 37 |
# File 'lib/fleetly/user.rb', line 32 def user_search(={}) [:oauth_token] = token user_me_response = get('/api/v1/users/search', ) user_me_response if user_me_response.result? end |