Class: LeanMicrosoftGraph::Resources::UsersResource
- Inherits:
-
LeanMicrosoftGraph::Resource
- Object
- LeanMicrosoftGraph::Resource
- LeanMicrosoftGraph::Resources::UsersResource
- Defined in:
- lib/lean_microsoft_graph/resources/users_resource.rb,
lib/lean_microsoft_graph/resources/users_resource/user.rb,
lib/lean_microsoft_graph/resources/users_resource/users.rb
Defined Under Namespace
Instance Method Summary collapse
- #count ⇒ Object
- #get_all(per_page) ⇒ Object
- #get_all_by_reference(url) ⇒ Object
- #get_user_by_id(user_id) ⇒ Object
Methods inherited from LeanMicrosoftGraph::Resource
#get_request, #initialize, #post_request
Constructor Details
This class inherits a constructor from LeanMicrosoftGraph::Resource
Instance Method Details
#count ⇒ Object
6 7 8 9 10 |
# File 'lib/lean_microsoft_graph/resources/users_resource.rb', line 6 def count get_request('users/$count') do |req| req.headers['ConsistencyLevel'] = 'eventual' end end |
#get_all(per_page) ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/lean_microsoft_graph/resources/users_resource.rb', line 12 def get_all(per_page) response = get_request('users') do |req| req.params['$top'] = per_page end Users.new(response) end |