msgraph-client 0.0.1 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: deb1e081a5adddf01fa0927f457f1732d39792cb69fbc6de29bd0ce550449677
4
- data.tar.gz: 951f00a6fabe765fda7541d29863f7e11b0f02ce6f62f9f0cc8b3771a657f115
3
+ metadata.gz: ba799cebce68bf4fd7501beb5e11117d88c93417913883754662aec4e5152e60
4
+ data.tar.gz: 1b06b76a57812cf79c383a987c1953388f7f1bb97495e4bea6b37d345d4bbc9c
5
5
  SHA512:
6
- metadata.gz: 758491707e84d1ba0dbfa482d8ceb0bd4400170d51b99097038a4d7c4d8824d1c29b72d02adbf1fa661d24c359cbdd4455d64ef985cb68a904a2032b6a3c7338
7
- data.tar.gz: 9d8e113d0e6ec50a58cde41422b92d4b7340263dea74e33be39cf6c9b75f59adc94b46ffcc52c12372da4fe8ec1d4d827c61bd3d5f2b97bea0f548e62454e571
6
+ metadata.gz: 1d40bdaa0dfb76d2fa71da5bc1e19cdf83e7298d93b5829a1319006e24937d6612816fd1c29ef64526fc68f2f0beac196a5187d6cdd107fa37e75bb85175b0c8
7
+ data.tar.gz: 0125c4a4164f0bb27e8b26df48b2db2c208df64c15654dc3fcb86f4bd2277821a4adef8633223a6124ab28a7b7a4d37608a7474bed47a5635809bde6ea6a02af
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2022 TODO: Write your name
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,60 @@
1
+ # MSGraph::Client
2
+
3
+ [![Gem Version](https://badge.fury.io/rb/msgraph-client.svg)](https://badge.fury.io/rb/msgraph-client)
4
+ ![Ruby](https://github.com/simayosi/rb-msgraph-client/actions/workflows/test.yml/badge.svg)
5
+
6
+
7
+ A simple client library for Microsoft Graph.
8
+
9
+
10
+ ## Installation
11
+
12
+ Add this line to your application's Gemfile:
13
+
14
+ ```ruby
15
+ gem 'msgraph-client'
16
+ ```
17
+
18
+ And then execute:
19
+
20
+ $ bundle install
21
+
22
+ Or install it yourself as:
23
+
24
+ $ gem install msgraph-client
25
+
26
+
27
+ ## Getting started
28
+
29
+ To call Graph API using this library, you need an access token.
30
+ A choice for aquiring the access token is
31
+ [MSIDP::Endpoint](https://github.com/simayosi/rb-msidp-endpoint).
32
+
33
+ ### Usage example
34
+ ```ruby
35
+ require 'msgraph/client'
36
+
37
+ client = MSGraph::Client.new
38
+
39
+ # Aquire an access token and set it to `token`
40
+
41
+ endpoint = "/v1.0/users?$filter=startswith(givenName, 'J')&$top=5"
42
+ # For paging
43
+ while endpoint
44
+ response = client.request(:get, endpoint, token)
45
+ response[:value].each do |user|
46
+ # do something
47
+ end
48
+ # Next page
49
+ endpoint = response[MSGraph::NEXT_LINK_KEY]
50
+ end
51
+ ```
52
+
53
+
54
+ ## API Reference
55
+ [RubyDoc.info](https://rubydoc.info/gems/msgraph-client)
56
+
57
+
58
+ ## License
59
+
60
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -2,6 +2,6 @@
2
2
 
3
3
  module MSGraph
4
4
  class Client
5
- VERSION = '0.0.1'
5
+ VERSION = '0.1.0'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: msgraph-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - SHIMAYOSHI, Takao
@@ -17,6 +17,8 @@ executables: []
17
17
  extensions: []
18
18
  extra_rdoc_files: []
19
19
  files:
20
+ - LICENSE.txt
21
+ - README.md
20
22
  - lib/msgraph/client.rb
21
23
  - lib/msgraph/client/version.rb
22
24
  - lib/msgraph/error.rb