codat 0.1.3 → 0.1.4

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: 815e3180acc27e45f704e7cd9ba4893d55774b47d6b0417020568538ba780490
4
- data.tar.gz: fcb66e4ccb57663cb4a1581d53271d2faecbba03602101e1758c981327101f63
3
+ metadata.gz: 9b359100d300f095792668b5566510b28d0c417c62884b09b82986c5e29ce050
4
+ data.tar.gz: f060ecf8c9fb2b2aab07cac48a16f76468bdcf1f650180cf041bf1873d95be7b
5
5
  SHA512:
6
- metadata.gz: 84e5b6c95805735f2f9429dd28f7edb3b74037796528a481ac991fadbf62148544007624b39228ada5c1747ed3adf7d933042baa76690898e8bb40134f67be91
7
- data.tar.gz: be197f35c8353eeb0136159c25517ff9af4609ca9f8b055dee54d08ad96251d7b952956edfec29452f4d0fa6abc798a2cd906d5ce75d7daf9c0bff09bde6ca80
6
+ metadata.gz: 2efbbac8dc086eaf8def830cc9abdbcdff3de04d17c4af1acd788533597c69a0c8f0b52ff3c1f46f119db2cc9aeaead363eb598786aa225ce11452d144be3f07
7
+ data.tar.gz: 6576d8cb03153ed9a409b0c95f94992a95387437a85abf7d7d4bc003f2a2c2c9f97e2914bd2be952834fafb7ef3321d526011ef7ca9a1040caba0f97861cc105
@@ -1,7 +1,7 @@
1
1
  before_script:
2
2
  - ruby -v
3
3
  - which ruby
4
- - gem install bundler --no-ri --no-rdoc
4
+ - gem install bundler
5
5
  - bundle install --jobs $(nproc) "${FLAGS[@]}"
6
6
 
7
7
  rspec:
@@ -0,0 +1 @@
1
+ 2.6.4
@@ -31,7 +31,7 @@ Gem::Specification.new do |spec|
31
31
  spec.add_dependency 'multi_json', '~> 1.13'
32
32
  spec.add_dependency 'rainbow', '~> 3.0'
33
33
 
34
- spec.add_development_dependency 'bundler', '~> 1.16'
34
+ spec.add_development_dependency 'bundler'
35
35
  spec.add_development_dependency 'dotenv', '~> 2.5'
36
36
  spec.add_development_dependency 'pry-byebug', '~> 3.6'
37
37
  spec.add_development_dependency 'rake', '~> 10.0'
@@ -40,5 +40,5 @@ Gem::Specification.new do |spec|
40
40
  spec.add_development_dependency 'rubocop-rspec', '~> 1.27'
41
41
  spec.add_development_dependency 'simplecov', '~> 0.16'
42
42
  spec.add_development_dependency 'vcr', '~> 4.0.0'
43
- spec.add_development_dependency 'webmock', '~> 3.4.2'
43
+ spec.add_development_dependency 'webmock', '~> 3.7.2'
44
44
  end
@@ -10,6 +10,7 @@ require 'codat/models/report'
10
10
  require 'codat/models/bank_statement_list'
11
11
  require 'codat/models/balance_sheet'
12
12
  require 'codat/models/profit_and_loss'
13
+ require 'codat/models/integration'
13
14
 
14
15
  module Codat
15
16
  module_function
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'codat/base_model'
4
+
5
+ module Codat
6
+ module Models
7
+ class Integration < BaseModel
8
+ ENDPOINT = '/integrations'
9
+
10
+ attributes :key, :logo_url, :name, :enabled, :source_id, :integration_id, :source_type
11
+
12
+ def self.all(params = {})
13
+ result = get(ENDPOINT, params)
14
+
15
+ return [] if result.status == 404
16
+
17
+ return result.body if result.status == 400
18
+
19
+ result.body.map { |integration| new(json: integration) }
20
+ end
21
+ end
22
+ end
23
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Codat
4
- VERSION = '0.1.3'
4
+ VERSION = '0.1.4'
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.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ricardo Otero
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-08 00:00:00.000000000 Z
11
+ date: 2019-09-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -84,16 +84,16 @@ dependencies:
84
84
  name: bundler
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - "~>"
87
+ - - ">="
88
88
  - !ruby/object:Gem::Version
89
- version: '1.16'
89
+ version: '0'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - "~>"
94
+ - - ">="
95
95
  - !ruby/object:Gem::Version
96
- version: '1.16'
96
+ version: '0'
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: dotenv
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -212,14 +212,14 @@ dependencies:
212
212
  requirements:
213
213
  - - "~>"
214
214
  - !ruby/object:Gem::Version
215
- version: 3.4.2
215
+ version: 3.7.2
216
216
  type: :development
217
217
  prerelease: false
218
218
  version_requirements: !ruby/object:Gem::Requirement
219
219
  requirements:
220
220
  - - "~>"
221
221
  - !ruby/object:Gem::Version
222
- version: 3.4.2
222
+ version: 3.7.2
223
223
  description: Codat API wrapper in Ruby
224
224
  email:
225
225
  - oterosantos@gmail.com
@@ -231,7 +231,7 @@ files:
231
231
  - ".gitlab-ci.yml"
232
232
  - ".rspec"
233
233
  - ".rubocop.yml"
234
- - ".travis.yml"
234
+ - ".ruby-version"
235
235
  - Gemfile
236
236
  - LICENSE.txt
237
237
  - README.md
@@ -253,6 +253,7 @@ files:
253
253
  - lib/codat/models/bank_statement_list.rb
254
254
  - lib/codat/models/company.rb
255
255
  - lib/codat/models/financial_sheet.rb
256
+ - lib/codat/models/integration.rb
256
257
  - lib/codat/models/metadata.rb
257
258
  - lib/codat/models/profit_and_loss.rb
258
259
  - lib/codat/models/profit_and_loss_report.rb
@@ -278,8 +279,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
278
279
  - !ruby/object:Gem::Version
279
280
  version: '0'
280
281
  requirements: []
281
- rubyforge_project:
282
- rubygems_version: 2.7.3
282
+ rubygems_version: 3.0.3
283
283
  signing_key:
284
284
  specification_version: 4
285
285
  summary: Codat API wrapper in Ruby
@@ -1,5 +0,0 @@
1
- sudo: false
2
- language: ruby
3
- rvm:
4
- - 2.5.0
5
- before_install: gem install bundler -v 1.16.1