invofox-api-ruby 0.1.3 → 0.1.5

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0b3b23128f3a968a7d39c6e9341fced0e6a8f6b980b5cc558cdefae1e11aab6f
4
- data.tar.gz: 69b10c217a0177465d04cec477533af61e1bdc0568c17357283046a158ec7e7d
3
+ metadata.gz: 1b55f4b8789b73ae12c82c5959381d2dc5c3b9bc138d73b5e847e9140ff514c4
4
+ data.tar.gz: 8ef148c97df52929f954811a7faf5bcc69e2d32e329f81fa9f734030e729ebbc
5
5
  SHA512:
6
- metadata.gz: 77d0c1b2eb38d4a38877268a988fdf8784b30ed74af3f7bf363887c3288cda3f3611938fffe380acc442c70174d5d4ba8d9dbf9a1f3c17b01bae4693238307de
7
- data.tar.gz: d26f9a1069835b38c8a05dc41f259efa1273d6640134cefa3aee21b4a75dfd605042f97a3ac8ffd7981672605ff54f0717c57d6f204bf1743c2559d7c3a5113c
6
+ metadata.gz: cc40d27baa239bfa4c5206b22f63aee504388d9108ec774e3cbcc5053080516cab363d034858246173145d0afe9343a6732b5481763ae8a05a4a597adde559a8
7
+ data.tar.gz: ec9d940fbac909d5e3394ff15e99a6c5afb02b1f19c17d98fe4fd59a2b53df6fa11799522b8bb0068600fc4fd7d184aad0b0330e624e6631493ebc5df2c68693
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- invofox-api-ruby (0.1.3)
4
+ invofox-api-ruby (0.1.4)
5
5
  rest-client (~> 2.0.2)
6
6
 
7
7
  GEM
@@ -20,7 +20,7 @@ GEM
20
20
  json (2.6.2)
21
21
  mime-types (3.5.2)
22
22
  mime-types-data (~> 3.2015)
23
- mime-types-data (3.2024.0305)
23
+ mime-types-data (3.2024.0507)
24
24
  netrc (0.11.0)
25
25
  parallel (1.22.1)
26
26
  parser (3.1.2.1)
data/README.md CHANGED
@@ -33,6 +33,8 @@ You can set a `logger` as well.
33
33
  Changelog
34
34
  ---------
35
35
 
36
+ * v.0.1.5 Fixes an issue sending booleans in POST and PUT requests.
37
+ * v.0.1.4 Ensure using JSON as content type.
36
38
  * v.0.1.3 Increase timeout to 5m.
37
39
  * v.0.1.2 Added support for companies' list endpoint.
38
40
  * v.0.1.1 Added support for documents' update_type endpoint.
data/lib/invofox/base.rb CHANGED
@@ -18,6 +18,7 @@ module Invofox
18
18
  # Prepare headers & params
19
19
  request_headers = {
20
20
  accept: 'application/json',
21
+ content_type: 'application/json',
21
22
  "x-api-key" => Invofox.configuration.api_key
22
23
  }
23
24
 
@@ -29,7 +30,7 @@ module Invofox
29
30
  }
30
31
 
31
32
  if method == :post || method == :put
32
- request_params[:payload] = params
33
+ request_params[:payload] = params.to_json
33
34
  else
34
35
  request_headers[:params] = params
35
36
  end
@@ -40,8 +40,8 @@ class Invofox::Document < Invofox::Resource
40
40
  params: {
41
41
  company: company_id,
42
42
  urls: url,
43
- closeBatch: true,
44
- useClassifier: true
43
+ closeBatch: "true",
44
+ useClassifier: "true"
45
45
  }
46
46
  ) do |response_body|
47
47
  response_body['result']['loadBatch']
@@ -1,3 +1,3 @@
1
1
  module Invofox
2
- VERSION = "0.1.3"
2
+ VERSION = "0.1.5"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: invofox-api-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Albert Bellonch
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-05-07 00:00:00.000000000 Z
11
+ date: 2024-05-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client