Module: SmartHR::Client::UserMethods
- Included in:
- SmartHR::Client
- Defined in:
- lib/smarthr/client/user_methods.rb
Instance Method Summary collapse
-
#find_user(id:, embed_crew: false) {|response_body, response_header| ... } ⇒ Hashie::Mash
Get the user.
-
#get_users(page: 1, per_page: 10, embed_crew: false) {|response_body, response_header| ... } ⇒ Array<Hashie::Mash>
Get the list of users.
Instance Method Details
#find_user(id:, embed_crew: false) {|response_body, response_header| ... } ⇒ Hashie::Mash
Get the user
14 15 16 |
# File 'lib/smarthr/client/user_methods.rb', line 14 def find_user(id:, embed_crew: false, &block) get("/users/#{id}", embed: ? 'crew' : nil, &block) end |
#get_users(page: 1, per_page: 10, embed_crew: false) {|response_body, response_header| ... } ⇒ Array<Hashie::Mash>
Get the list of users
31 32 33 34 35 36 37 38 |
# File 'lib/smarthr/client/user_methods.rb', line 31 def get_users(page: 1, per_page: 10, embed_crew: false, &block) get("/users", page: page, per_page: per_page, embed: ? 'crew' : nil, &block ) end |