oneaccess 0.4.4 → 0.4.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +3 -0
- data/Gemfile +1 -0
- data/README.md +2 -1
- data/Rakefile +1 -0
- data/lib/oneaccess/api/v1_1/base.rb +1 -1
- data/lib/oneaccess/api/v1_1/entitlement/organization/product_group.rb +2 -1
- data/lib/oneaccess/api/v1_1/entitlement/research/user_requests.rb +1 -1
- data/lib/oneaccess/api/v1_1/entitlement/user/product_group.rb +2 -1
- data/lib/oneaccess/api/v1_1/entitlement/user_subscription.rb +1 -1
- data/lib/oneaccess/api/v1_1/organizations.rb +1 -1
- data/lib/oneaccess/api/v1_1/references.rb +1 -1
- data/lib/oneaccess/api/v1_1/research.rb +2 -1
- data/lib/oneaccess/api/v1_1/symbology.rb +1 -1
- data/lib/oneaccess/api/v1_1/user.rb +2 -1
- data/lib/oneaccess/api/v3_0/base.rb +1 -1
- data/lib/oneaccess/api/v3_0/providers.rb +2 -2
- data/lib/oneaccess/api/v3_0/references.rb +1 -1
- data/lib/oneaccess/configuration.rb +1 -0
- data/lib/oneaccess/data_object/address.rb +1 -0
- data/lib/oneaccess/data_object/city.rb +1 -0
- data/lib/oneaccess/data_object/country.rb +1 -0
- data/lib/oneaccess/data_object/global_region.rb +1 -0
- data/lib/oneaccess/data_object/inducement.rb +1 -0
- data/lib/oneaccess/data_object/meta.rb +1 -0
- data/lib/oneaccess/data_object/organization.rb +1 -0
- data/lib/oneaccess/data_object/product_group.rb +1 -0
- data/lib/oneaccess/data_object/region.rb +1 -0
- data/lib/oneaccess/data_object/representer/address.rb +1 -0
- data/lib/oneaccess/data_object/representer/city.rb +1 -0
- data/lib/oneaccess/data_object/representer/country.rb +1 -0
- data/lib/oneaccess/data_object/representer/global_region.rb +1 -0
- data/lib/oneaccess/data_object/representer/inducement.rb +2 -2
- data/lib/oneaccess/data_object/representer/industry.rb +1 -0
- data/lib/oneaccess/data_object/representer/product_group.rb +1 -0
- data/lib/oneaccess/data_object/representer/region.rb +1 -0
- data/lib/oneaccess/data_object/representer/research_document_info.rb +1 -0
- data/lib/oneaccess/data_object/representer/saml_info.rb +1 -0
- data/lib/oneaccess/data_object/representer/user.rb +1 -0
- data/lib/oneaccess/data_object/research_document_info.rb +1 -0
- data/lib/oneaccess/data_object/saml_info.rb +1 -0
- data/lib/oneaccess/data_object/user.rb +1 -0
- data/lib/oneaccess/enum/api_status_code.rb +1 -0
- data/lib/oneaccess/enum/product_group_status.rb +1 -0
- data/lib/oneaccess/enum/product_type.rb +1 -0
- data/lib/oneaccess/error/api_error.rb +1 -0
- data/lib/oneaccess/response/api_error.rb +1 -0
- data/lib/oneaccess/response/organization_response.rb +1 -0
- data/lib/oneaccess/response/representer/api_error.rb +1 -0
- data/lib/oneaccess/serializable.rb +1 -0
- data/oneaccess.gemspec +7 -6
- metadata +27 -27
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8a04af112ed6e47d0c4f118cd95d356f7342a1c1
|
4
|
+
data.tar.gz: e89480e74840ed6d2649f7c85f41906a25834244
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc82b3f2c18cabaa72cef280fd79cea24b60d463c9ac0fa5ea1ace1a16e2b4c92c2cd747223fa2dd8ba6349c9595a43398aee754858083852aeab77661e32204
|
7
|
+
data.tar.gz: 15750546f7085327cc303bdbe8a5897c6ee9c138d87cb0626136dde89a85628fbc362f4e0534087f6d4ae17d338218ade674b26b02ef60b9fc941c9c80df4fa3
|
data/.rubocop.yml
CHANGED
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -43,6 +43,7 @@ Not all the methods in the API are currently supported, here's a list of all sup
|
|
43
43
|
- User Entitlement Requests: _/entitlement/research/userRequests/getListWithEntitlementsStatus_
|
44
44
|
- Subscribe to Entitlements Updates: _/entitlement/userSubscription/subscribeToUpdates_
|
45
45
|
- Get User ids which entitlements have changed _/entitlement/userSubscription/subscribeToUpdates/changedUsers/getList_
|
46
|
+
- Create email inducement: _/providers/inducements_
|
46
47
|
|
47
48
|
### User by Email _(/user/getByEmail)_
|
48
49
|
Official Documentation: http://apidocs.oneaccess.io/docs/usergetorcreate
|
@@ -51,7 +52,7 @@ This method returns a `User` object if it matches the first name, last name, and
|
|
51
52
|
|
52
53
|
#### How to use:
|
53
54
|
```ruby
|
54
|
-
resp = ONEAccess::API::V1_1::User.
|
55
|
+
resp = ONEAccess::API::V1_1::User.get_by_email(first_name: 'Alex', last_name: 'Santos', email: 'alex@ae.com')
|
55
56
|
|
56
57
|
resp.data #=> instance of ONEAccess::DataObject::User
|
57
58
|
resp.data.id #=> 305 (id of the user)
|
data/Rakefile
CHANGED
@@ -1,9 +1,10 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
|
+
|
2
3
|
require_relative "../../../../response/product_groups_response"
|
3
4
|
|
4
5
|
module ONEAccess
|
5
6
|
module API
|
6
|
-
module V1_1
|
7
|
+
module V1_1
|
7
8
|
module Entitlement
|
8
9
|
module Organization
|
9
10
|
class ProductGroup < Base
|
@@ -1,9 +1,10 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
|
+
|
2
3
|
require_relative "../../../../response/product_groups_response"
|
3
4
|
|
4
5
|
module ONEAccess
|
5
6
|
module API
|
6
|
-
module V1_1
|
7
|
+
module V1_1
|
7
8
|
module Entitlement
|
8
9
|
module User
|
9
10
|
class ProductGroup < Base
|
@@ -5,7 +5,7 @@ require_relative "../../../response/changed_users_response"
|
|
5
5
|
|
6
6
|
module ONEAccess
|
7
7
|
module API
|
8
|
-
module V1_1
|
8
|
+
module V1_1
|
9
9
|
module Entitlement
|
10
10
|
class UserSubscription < Base
|
11
11
|
api_path "/entitlement/userSubscription"
|
@@ -4,7 +4,7 @@ require_relative "../../response/inducement_response"
|
|
4
4
|
|
5
5
|
module ONEAccess
|
6
6
|
module API
|
7
|
-
module V3_0
|
7
|
+
module V3_0
|
8
8
|
class Providers < Base
|
9
9
|
api_path "/providers"
|
10
10
|
|
@@ -18,7 +18,7 @@ module ONEAccess
|
|
18
18
|
receivedate: receive_date
|
19
19
|
}.reject { |_, v| v.nil? }
|
20
20
|
|
21
|
-
resp = send_post("inducements",
|
21
|
+
resp = send_post("inducements", inducement: params)
|
22
22
|
|
23
23
|
Response::InducementResponse.from_json(resp.body)
|
24
24
|
end
|
@@ -7,7 +7,7 @@ module ONEAccess
|
|
7
7
|
include Representable::JSON
|
8
8
|
|
9
9
|
property :receive_date, as: :ReceiveDate, type: Time,
|
10
|
-
parse_filter: ->(value, _) { value
|
10
|
+
parse_filter: ->(value, _) { value&.size&.positive? ? Time.parse(value) : nil }
|
11
11
|
property :provider_org_id, as: :ProviderOrgId, type: Integer
|
12
12
|
property :email_inducement_id, as: :EmailInducementId, type: Integer
|
13
13
|
property :recipient_user_id, as: :RecipientUserId, type: Integer
|
@@ -15,7 +15,7 @@ module ONEAccess
|
|
15
15
|
property :email_inducement_status_id, as: :EmailInducementStatusId, type: Integer
|
16
16
|
property :body, as: :Body, type: String
|
17
17
|
property :processed_date, as: :ProcessedDate, type: Time,
|
18
|
-
parse_filter: ->(value, _) { value
|
18
|
+
parse_filter: ->(value, _) { value&.size&.positive? ? Time.parse(value) : nil }
|
19
19
|
property :subject, as: :Subject, type: String
|
20
20
|
end
|
21
21
|
end
|
data/oneaccess.gemspec
CHANGED
@@ -1,7 +1,8 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
|
+
|
2
3
|
Gem::Specification.new do |s|
|
3
4
|
s.name = "oneaccess"
|
4
|
-
s.version = "0.4.
|
5
|
+
s.version = "0.4.5"
|
5
6
|
s.date = "2018-03-17"
|
6
7
|
s.summary = "ONEAccess API wrapper"
|
7
8
|
s.description = "Easily communicate with ONEAccess API"
|
@@ -12,18 +13,18 @@ Gem::Specification.new do |s|
|
|
12
13
|
s.require_paths = ["lib"]
|
13
14
|
s.license = "MIT"
|
14
15
|
|
15
|
-
s.required_ruby_version = ">= 2.
|
16
|
+
s.required_ruby_version = ">= 2.3"
|
16
17
|
|
17
18
|
s.add_development_dependency "bundler", "~> 1.12"
|
18
|
-
s.add_development_dependency "
|
19
|
+
s.add_development_dependency "byebug"
|
19
20
|
s.add_development_dependency "rake", "~> 11.3"
|
21
|
+
s.add_development_dependency "rspec", "~> 3.6"
|
20
22
|
s.add_development_dependency "rubocop", "~> 0.45.0"
|
21
|
-
s.add_development_dependency "webmock", "~> 3.0.1"
|
22
23
|
s.add_development_dependency "simplecov"
|
23
24
|
s.add_development_dependency "simplecov-console"
|
24
|
-
s.add_development_dependency "
|
25
|
+
s.add_development_dependency "webmock", "~> 3.0.1"
|
25
26
|
|
27
|
+
s.add_runtime_dependency "multi_json", "~> 1.12.0"
|
26
28
|
s.add_runtime_dependency "representable", "~> 3.0.4"
|
27
29
|
s.add_runtime_dependency "rest-client", "~> 2.0.0"
|
28
|
-
s.add_runtime_dependency "multi_json", "~> 1.12.0"
|
29
30
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: oneaccess
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Correia Santos
|
@@ -25,19 +25,19 @@ dependencies:
|
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '1.12'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
28
|
+
name: byebug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '0'
|
34
34
|
type: :development
|
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: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -53,33 +53,33 @@ dependencies:
|
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '11.3'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: rspec
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: '3.6'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: '3.6'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
70
|
+
name: rubocop
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
73
|
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
75
|
+
version: 0.45.0
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
82
|
+
version: 0.45.0
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: simplecov
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -109,61 +109,61 @@ dependencies:
|
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
|
-
name:
|
112
|
+
name: webmock
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
114
114
|
requirements:
|
115
|
-
- - "
|
115
|
+
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version:
|
117
|
+
version: 3.0.1
|
118
118
|
type: :development
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
|
-
- - "
|
122
|
+
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version:
|
124
|
+
version: 3.0.1
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
|
-
name:
|
126
|
+
name: multi_json
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
128
128
|
requirements:
|
129
129
|
- - "~>"
|
130
130
|
- !ruby/object:Gem::Version
|
131
|
-
version:
|
131
|
+
version: 1.12.0
|
132
132
|
type: :runtime
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
136
|
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
|
-
version:
|
138
|
+
version: 1.12.0
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
|
-
name:
|
140
|
+
name: representable
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|
142
142
|
requirements:
|
143
143
|
- - "~>"
|
144
144
|
- !ruby/object:Gem::Version
|
145
|
-
version:
|
145
|
+
version: 3.0.4
|
146
146
|
type: :runtime
|
147
147
|
prerelease: false
|
148
148
|
version_requirements: !ruby/object:Gem::Requirement
|
149
149
|
requirements:
|
150
150
|
- - "~>"
|
151
151
|
- !ruby/object:Gem::Version
|
152
|
-
version:
|
152
|
+
version: 3.0.4
|
153
153
|
- !ruby/object:Gem::Dependency
|
154
|
-
name:
|
154
|
+
name: rest-client
|
155
155
|
requirement: !ruby/object:Gem::Requirement
|
156
156
|
requirements:
|
157
157
|
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version:
|
159
|
+
version: 2.0.0
|
160
160
|
type: :runtime
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version:
|
166
|
+
version: 2.0.0
|
167
167
|
description: Easily communicate with ONEAccess API
|
168
168
|
email:
|
169
169
|
- alex@alpha-exchange.com
|
@@ -302,7 +302,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
302
302
|
requirements:
|
303
303
|
- - ">="
|
304
304
|
- !ruby/object:Gem::Version
|
305
|
-
version: 2.
|
305
|
+
version: '2.3'
|
306
306
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
307
307
|
requirements:
|
308
308
|
- - ">="
|