codat 0.1.5 → 0.1.6.1

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: d09022df4a8325e87d98203d4441da3bb0767abc37b654c2ed2b0901d0f45f4b
4
- data.tar.gz: f75d4d5a4e8ef1f66201e53d70ea8449d289e18ca0b7355dbd8484a112bb6a6b
3
+ metadata.gz: 70707b14ad426a89a08c86266fbad954d69621817a08185405c890f8862c82e3
4
+ data.tar.gz: 9a8e92a6563be17ec4f9ceb92045077b8bc14fb39a9b97aeb875c6196c47e532
5
5
  SHA512:
6
- metadata.gz: ee8f01dfbe68c0b176164b054e6191bf9bf2b68dc6c87740eaf6bab195c6dc9e8724b35dd3179612bb2778d12a69da7b20c9db5adbec0595c6330392504c85af
7
- data.tar.gz: f94df3242b171c2c63d5c130505484143c81697dce53b9d714817f53f28f329f3872c9b147376abcc57fe5664034e844b1a000c49f67ef00beb1fe0387b041be
6
+ metadata.gz: ccbb595335689a4a424e4c767e7710046a1a6d3dc06f507e93ff0d37df5bfe7ea808e3bdde29ebe31103174dd067fcd51e98a507e7b2aef25eb5dc104e6fe3d2
7
+ data.tar.gz: 1054a5856b663c9168138c044d5cf3b5eacff7c492ce220f93fc51e31a37e1290286bfc2cbe65908d929911633ee9cf752ce39590442d3b0e47b9c44050de51c
data/.gitignore CHANGED
@@ -8,6 +8,7 @@
8
8
  /spec/reports/
9
9
  /tmp/
10
10
  Gemfile.lock
11
+ .DS_Store
11
12
 
12
13
  # rspec failure tracking
13
14
  .rspec_status
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.6.4
1
+ 2.6.6
data/Gemfile CHANGED
@@ -6,3 +6,14 @@ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
6
6
 
7
7
  # Specify your gem's dependencies in codat.gemspec
8
8
  gemspec
9
+
10
+ # Development dependencies
11
+ gem 'dotenv'
12
+ gem 'pry-byebug'
13
+ gem 'rake'
14
+ gem 'rspec'
15
+ gem 'rubocop'
16
+ gem 'rubocop-rspec'
17
+ gem 'simplecov'
18
+ gem 'vcr'
19
+ gem 'webmock'
data/codat.gemspec CHANGED
@@ -25,20 +25,9 @@ Gem::Specification.new do |spec|
25
25
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
26
26
  spec.require_paths = ['lib']
27
27
 
28
- spec.add_dependency 'faraday', '~> 0.15'
29
- spec.add_dependency 'faraday_middleware', '~> 0.12'
30
- spec.add_dependency 'faraday_middleware-multi_json', '~> 0.0.6'
31
- spec.add_dependency 'multi_json', '~> 1.13'
32
- spec.add_dependency 'rainbow', '~> 3.0'
33
-
34
- spec.add_development_dependency 'bundler'
35
- spec.add_development_dependency 'dotenv', '~> 2.5'
36
- spec.add_development_dependency 'pry-byebug', '~> 3.6'
37
- spec.add_development_dependency 'rake', '~> 10.0'
38
- spec.add_development_dependency 'rspec', '~> 3.0'
39
- spec.add_development_dependency 'rubocop', '~> 0.58'
40
- spec.add_development_dependency 'rubocop-rspec', '~> 1.27'
41
- spec.add_development_dependency 'simplecov', '~> 0.16'
42
- spec.add_development_dependency 'vcr', '~> 4.0.0'
43
- spec.add_development_dependency 'webmock', '~> 3.7.2'
28
+ spec.required_ruby_version = '>= 2.5'
29
+
30
+ spec.add_dependency 'faraday', '~> 2.7'
31
+ spec.add_dependency 'multi_json'
32
+ spec.add_dependency 'rainbow'
44
33
  end
data/lib/codat/client.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'faraday'
4
- require 'faraday_middleware/multi_json'
4
+ require 'multi_json'
5
5
  require 'codat/faraday_codat_auth'
6
6
 
7
7
  module Codat
@@ -26,7 +26,7 @@ module Codat
26
26
  def connection
27
27
  @connection ||= Faraday.new(url: api_url) do |conn|
28
28
  conn.request :codat_auth, Codat.configuration.api_key
29
- conn.response :multi_json, symbolize_keys: true
29
+ conn.response :json, parser_options: { symbolize_names: true }
30
30
  # conn.response :logger # if Codat.configuration.debug?
31
31
  conn.adapter Faraday.default_adapter
32
32
  end
@@ -14,7 +14,7 @@ module Codat
14
14
 
15
15
  return [] unless successful_response?(result)
16
16
 
17
- result.body.map { |integration| new(json: integration) }
17
+ result.body.fetch(:results, []).map { |integration| new(json: integration) }
18
18
  end
19
19
  end
20
20
  end
data/lib/codat/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Codat
4
- VERSION = '0.1.5'
4
+ VERSION = '0.1.6.1'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: codat
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ricardo Otero
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-01-05 00:00:00.000000000 Z
11
+ date: 2023-03-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -16,210 +16,42 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0.15'
19
+ version: '2.7'
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: '0.15'
27
- - !ruby/object:Gem::Dependency
28
- name: faraday_middleware
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - "~>"
32
- - !ruby/object:Gem::Version
33
- version: '0.12'
34
- type: :runtime
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - "~>"
39
- - !ruby/object:Gem::Version
40
- version: '0.12'
41
- - !ruby/object:Gem::Dependency
42
- name: faraday_middleware-multi_json
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: 0.0.6
48
- type: :runtime
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: 0.0.6
26
+ version: '2.7'
55
27
  - !ruby/object:Gem::Dependency
56
28
  name: multi_json
57
29
  requirement: !ruby/object:Gem::Requirement
58
30
  requirements:
59
- - - "~>"
31
+ - - ">="
60
32
  - !ruby/object:Gem::Version
61
- version: '1.13'
33
+ version: '0'
62
34
  type: :runtime
63
35
  prerelease: false
64
36
  version_requirements: !ruby/object:Gem::Requirement
65
37
  requirements:
66
- - - "~>"
38
+ - - ">="
67
39
  - !ruby/object:Gem::Version
68
- version: '1.13'
40
+ version: '0'
69
41
  - !ruby/object:Gem::Dependency
70
42
  name: rainbow
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '3.0'
76
- type: :runtime
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: '3.0'
83
- - !ruby/object:Gem::Dependency
84
- name: bundler
85
43
  requirement: !ruby/object:Gem::Requirement
86
44
  requirements:
87
45
  - - ">="
88
46
  - !ruby/object:Gem::Version
89
47
  version: '0'
90
- type: :development
48
+ type: :runtime
91
49
  prerelease: false
92
50
  version_requirements: !ruby/object:Gem::Requirement
93
51
  requirements:
94
52
  - - ">="
95
53
  - !ruby/object:Gem::Version
96
54
  version: '0'
97
- - !ruby/object:Gem::Dependency
98
- name: dotenv
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: '2.5'
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: '2.5'
111
- - !ruby/object:Gem::Dependency
112
- name: pry-byebug
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '3.6'
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - "~>"
123
- - !ruby/object:Gem::Version
124
- version: '3.6'
125
- - !ruby/object:Gem::Dependency
126
- name: rake
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - "~>"
130
- - !ruby/object:Gem::Version
131
- version: '10.0'
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - "~>"
137
- - !ruby/object:Gem::Version
138
- version: '10.0'
139
- - !ruby/object:Gem::Dependency
140
- name: rspec
141
- requirement: !ruby/object:Gem::Requirement
142
- requirements:
143
- - - "~>"
144
- - !ruby/object:Gem::Version
145
- version: '3.0'
146
- type: :development
147
- prerelease: false
148
- version_requirements: !ruby/object:Gem::Requirement
149
- requirements:
150
- - - "~>"
151
- - !ruby/object:Gem::Version
152
- version: '3.0'
153
- - !ruby/object:Gem::Dependency
154
- name: rubocop
155
- requirement: !ruby/object:Gem::Requirement
156
- requirements:
157
- - - "~>"
158
- - !ruby/object:Gem::Version
159
- version: '0.58'
160
- type: :development
161
- prerelease: false
162
- version_requirements: !ruby/object:Gem::Requirement
163
- requirements:
164
- - - "~>"
165
- - !ruby/object:Gem::Version
166
- version: '0.58'
167
- - !ruby/object:Gem::Dependency
168
- name: rubocop-rspec
169
- requirement: !ruby/object:Gem::Requirement
170
- requirements:
171
- - - "~>"
172
- - !ruby/object:Gem::Version
173
- version: '1.27'
174
- type: :development
175
- prerelease: false
176
- version_requirements: !ruby/object:Gem::Requirement
177
- requirements:
178
- - - "~>"
179
- - !ruby/object:Gem::Version
180
- version: '1.27'
181
- - !ruby/object:Gem::Dependency
182
- name: simplecov
183
- requirement: !ruby/object:Gem::Requirement
184
- requirements:
185
- - - "~>"
186
- - !ruby/object:Gem::Version
187
- version: '0.16'
188
- type: :development
189
- prerelease: false
190
- version_requirements: !ruby/object:Gem::Requirement
191
- requirements:
192
- - - "~>"
193
- - !ruby/object:Gem::Version
194
- version: '0.16'
195
- - !ruby/object:Gem::Dependency
196
- name: vcr
197
- requirement: !ruby/object:Gem::Requirement
198
- requirements:
199
- - - "~>"
200
- - !ruby/object:Gem::Version
201
- version: 4.0.0
202
- type: :development
203
- prerelease: false
204
- version_requirements: !ruby/object:Gem::Requirement
205
- requirements:
206
- - - "~>"
207
- - !ruby/object:Gem::Version
208
- version: 4.0.0
209
- - !ruby/object:Gem::Dependency
210
- name: webmock
211
- requirement: !ruby/object:Gem::Requirement
212
- requirements:
213
- - - "~>"
214
- - !ruby/object:Gem::Version
215
- version: 3.7.2
216
- type: :development
217
- prerelease: false
218
- version_requirements: !ruby/object:Gem::Requirement
219
- requirements:
220
- - - "~>"
221
- - !ruby/object:Gem::Version
222
- version: 3.7.2
223
55
  description: Codat API wrapper in Ruby
224
56
  email:
225
57
  - oterosantos@gmail.com
@@ -272,14 +104,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
272
104
  requirements:
273
105
  - - ">="
274
106
  - !ruby/object:Gem::Version
275
- version: '0'
107
+ version: '2.5'
276
108
  required_rubygems_version: !ruby/object:Gem::Requirement
277
109
  requirements:
278
110
  - - ">="
279
111
  - !ruby/object:Gem::Version
280
112
  version: '0'
281
113
  requirements: []
282
- rubygems_version: 3.0.3
114
+ rubygems_version: 3.2.3
283
115
  signing_key:
284
116
  specification_version: 4
285
117
  summary: Codat API wrapper in Ruby