omniauth-cybozu 0.0.1 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/README.md +13 -7
- data/lib/omniauth-cybozu/version.rb +1 -1
- data/omniauth-cybozu.gemspec +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9bcf1bb41a133a217c8dbf4058e46389dc3e0c01c9d4a9d3612317e40054b127
|
|
4
|
+
data.tar.gz: 5105c587dac5346ea6491f8a287e7fa33f336cf010d8346d328af076fea9ebf0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8a93a2d28e84cb26c1b3052f216e83340a9e87e4da853775870f4b8492e7d094b3797d704aa6bd46e27a359125350b783a322a399f9ed45f5f0b373578196f8e
|
|
7
|
+
data.tar.gz: 75b0d298187a4e7922532a8acad3bcdbe8b88396c95c46fc09cfc53a0a67a41008108f1a6a916a9e1c81671d6494fe5b263884ac0d827f323bc504d924dbf223
|
data/CHANGELOG.md
ADDED
data/README.md
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
[](http://badge.fury.io/rb/omniauth-cybozu)
|
|
4
4
|
|
|
5
|
-
This gem contains
|
|
5
|
+
This gem contains [Kintone](https://www.kintone.com/) and [Garoon](https://garoon.cybozu.co.jp/) strategy for OmniAuth.
|
|
6
6
|
|
|
7
7
|
## Before You Begin
|
|
8
8
|
|
|
9
9
|
You should have already installed OmniAuth into your app; if not, read the [OmniAuth README](https://github.com/intridea/omniauth) to get started.
|
|
10
10
|
|
|
11
|
-
Now sign into the [Kintone Developer Program](https://developer.kintone.io/hc/en-us/) and create an application. Take note of your API keys
|
|
11
|
+
Now sign into the [Kintone Developer Program](https://developer.kintone.io/hc/en-us/) or [cybozu developer network](https://developer.cybozu.io/hc/ja) and create an application. Take note of your API keys.
|
|
12
12
|
|
|
13
13
|
## Using This Strategy
|
|
14
14
|
|
|
@@ -29,11 +29,17 @@ Next, tell OmniAuth about this provider. For a Rails app, your `config/initializ
|
|
|
29
29
|
```ruby
|
|
30
30
|
Rails.application.config.middleware.use OmniAuth::Builder do
|
|
31
31
|
|
|
32
|
-
#
|
|
33
|
-
|
|
32
|
+
# For kintone.com user
|
|
33
|
+
# Kintone records writable
|
|
34
|
+
kintone_site = 'https://{subdomain}.kintone.com'
|
|
35
|
+
kintone_scope = ['k:app_record:read', 'k:app_record:write'].join(' ')
|
|
36
|
+
provider :cybozu, "CLIENT_ID", "CLIENT_SECRET", { scope: kintone_scope, client_options: { site: kintone_site }}
|
|
34
37
|
|
|
35
|
-
#
|
|
36
|
-
|
|
38
|
+
# For cybozu.com user
|
|
39
|
+
# Garoon schedules writable
|
|
40
|
+
cybozu_site = 'https://{subdomain}.cybozu.com'
|
|
41
|
+
cybozu_scope = ['g:schedule:read', 'g:schedule:write'].join(' ')
|
|
42
|
+
provider :cybozu, "CLIENT_ID", "CLIENT_SECRET", :scope => cybozu_scope, :client_options => {:site => cybozu_site}
|
|
37
43
|
|
|
38
44
|
end
|
|
39
45
|
```
|
|
@@ -47,7 +53,7 @@ The auth hash `request.env['omniauth.auth']` would look like this:
|
|
|
47
53
|
|
|
48
54
|
```js
|
|
49
55
|
{
|
|
50
|
-
"provider": "
|
|
56
|
+
"provider": "cybozu",
|
|
51
57
|
"uid": null, // uid will be empty, because there is no apis to get.
|
|
52
58
|
"credentials": {
|
|
53
59
|
"token": "ACCESS_TOKEN",
|
data/omniauth-cybozu.gemspec
CHANGED
|
@@ -8,7 +8,7 @@ Gem::Specification.new do |spec|
|
|
|
8
8
|
spec.authors = ['Kenji Koshikawa']
|
|
9
9
|
spec.email = ['koshikawa2009@gmail.com']
|
|
10
10
|
|
|
11
|
-
spec.summary = 'OmniAuth strategy for
|
|
11
|
+
spec.summary = 'OmniAuth strategy for cybozu(Kintone and Garoon)'
|
|
12
12
|
spec.description = spec.description
|
|
13
13
|
spec.homepage = 'https://github.com/koshilife/omniauth-cybozu'
|
|
14
14
|
spec.license = 'MIT'
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: omniauth-cybozu
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Kenji Koshikawa
|
|
@@ -77,6 +77,7 @@ files:
|
|
|
77
77
|
- ".rspec"
|
|
78
78
|
- ".rubocop.yml"
|
|
79
79
|
- ".travis.yml"
|
|
80
|
+
- CHANGELOG.md
|
|
80
81
|
- CODE_OF_CONDUCT.md
|
|
81
82
|
- Gemfile
|
|
82
83
|
- LICENSE.txt
|
|
@@ -114,5 +115,5 @@ requirements: []
|
|
|
114
115
|
rubygems_version: 3.1.3
|
|
115
116
|
signing_key:
|
|
116
117
|
specification_version: 4
|
|
117
|
-
summary: OmniAuth strategy for
|
|
118
|
+
summary: OmniAuth strategy for cybozu(Kintone and Garoon)
|
|
118
119
|
test_files: []
|