agx 0.1.5 → 0.2.0
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/README.md +2 -2
- data/agx.gemspec +2 -2
- data/lib/agx/sync/client.rb +4 -3
- data/lib/agx/version.rb +1 -1
- metadata +10 -10
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 6757c8bcbacdc7d646a5378085660012c46155f9
|
|
4
|
+
data.tar.gz: b31be8a6b2885075817a20937d03a5d218f3878a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4b6e5172e7afec61d020a279302a47fba64a7ef77ea0a846d17bb0b71be4bfe1c697134fbb3e057472febdb7de4ade587caac2f6435f7987744592f2c7cfaac4
|
|
7
|
+
data.tar.gz: 1df9291443ea6a451a448e0df9daf9b04421adc57c84f880448e70ab08784318f36a77a68a0c4541e4aa55c805d3cba90857a404f8a0e44b963ff422c3fd3db8
|
data/README.md
CHANGED
|
@@ -49,7 +49,7 @@ weeds = @agx_content_client.get("Weed", {publishDate: date.to_s})
|
|
|
49
49
|
|
|
50
50
|
### agX Sync API
|
|
51
51
|
|
|
52
|
-
Setup agX Sync Client (OAuth 2 Authorization Code Flow)
|
|
52
|
+
Setup agX Sync v4 Client (OAuth 2.0 / OpenID Connect 1.0 Authorization Code Flow)
|
|
53
53
|
|
|
54
54
|
***This requires that you have already previously authenticated and authorized
|
|
55
55
|
a user to agX through the authorization code grant flow process and have
|
|
@@ -60,7 +60,7 @@ expiration timestamp.***
|
|
|
60
60
|
@agx_sync_client = Agx::Sync::Client.new(
|
|
61
61
|
client_id: "your_client_id",
|
|
62
62
|
client_secret: "your_client_secret",
|
|
63
|
-
version: "
|
|
63
|
+
version: "v4", # optional
|
|
64
64
|
sync_id: "agx_user_sync_id",
|
|
65
65
|
access_token: "agx_user_agx_token",
|
|
66
66
|
refresh_token: "agx_user_refresh_token",
|
data/agx.gemspec
CHANGED
|
@@ -19,8 +19,8 @@ Gem::Specification.new do |spec|
|
|
|
19
19
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
20
20
|
spec.require_paths = ["lib"]
|
|
21
21
|
|
|
22
|
-
spec.add_dependency "oj", "
|
|
23
|
-
spec.add_dependency "oauth2", "
|
|
22
|
+
spec.add_dependency "oj", "< 4"
|
|
23
|
+
spec.add_dependency "oauth2", "< 2"
|
|
24
24
|
|
|
25
25
|
spec.add_development_dependency "bundler", "~> 1.12"
|
|
26
26
|
spec.add_development_dependency "rake", "~> 10.0"
|
data/lib/agx/sync/client.rb
CHANGED
|
@@ -13,9 +13,10 @@ module Agx
|
|
|
13
13
|
@client_secret = client_secret || ENV['AGX_SYNC_CLIENT_SECRET']
|
|
14
14
|
@site = "https://sync.#{domain}"
|
|
15
15
|
@host = host || "sync.#{domain}"
|
|
16
|
-
@authorize_url = "https://auth.#{domain}/
|
|
17
|
-
@token_url = "https://auth.#{domain}/
|
|
18
|
-
@
|
|
16
|
+
@authorize_url = "https://auth.#{domain}/identity/connect/Authorize"
|
|
17
|
+
@token_url = "https://auth.#{domain}/identity/connect/Token"
|
|
18
|
+
@oic_config_url = "https://auth.#{domain}/.well-known/openid- configuration"
|
|
19
|
+
@version = version || "v4"
|
|
19
20
|
@sync_id = sync_id
|
|
20
21
|
@api_url = "#{@site}/api/#{@version}/Account/#{@sync_id}/"
|
|
21
22
|
@headers = {
|
data/lib/agx/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,43 +1,43 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: agx
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Bryce Johnston
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-05-
|
|
11
|
+
date: 2017-05-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: oj
|
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
|
16
16
|
requirements:
|
|
17
|
-
- - "
|
|
17
|
+
- - "<"
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: '
|
|
19
|
+
version: '4'
|
|
20
20
|
type: :runtime
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
24
|
-
- - "
|
|
24
|
+
- - "<"
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: '
|
|
26
|
+
version: '4'
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
28
|
name: oauth2
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
|
30
30
|
requirements:
|
|
31
|
-
- - "
|
|
31
|
+
- - "<"
|
|
32
32
|
- !ruby/object:Gem::Version
|
|
33
|
-
version: '
|
|
33
|
+
version: '2'
|
|
34
34
|
type: :runtime
|
|
35
35
|
prerelease: false
|
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
|
37
37
|
requirements:
|
|
38
|
-
- - "
|
|
38
|
+
- - "<"
|
|
39
39
|
- !ruby/object:Gem::Version
|
|
40
|
-
version: '
|
|
40
|
+
version: '2'
|
|
41
41
|
- !ruby/object:Gem::Dependency
|
|
42
42
|
name: bundler
|
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|