chimera_http_client 1.5.0 → 1.5.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: da90ccc4dfdbaf080bf84581cebbf3344e85793653605ecf49075a524c4ecef2
4
- data.tar.gz: 5b93585a12aad3e8c927853e44dd0bc9b22b61f606edd7d3627a89ec91879cc2
3
+ metadata.gz: e14b26c79080837393064bdccc64a6bb4f994d4938258480b264eebf06136cf2
4
+ data.tar.gz: 42e0af5e1ac6aa1dd6adeb67b10d51c050ea239d9065c81be674b8b120337f88
5
5
  SHA512:
6
- metadata.gz: 805969007906d493de7b720747c7235345ad12022711f616557944053b7b57310ff587a3f381d081a68f9d63525a176f85dc1a67dc5002b5a4c01a939dea0ceb
7
- data.tar.gz: ffc28a398833e72ae2e760826e418dff7a7d5221e61443974c3bff4277ada7f2c9c1e71e7b1b7da3b20fc1251ccabd4d15c1f646061c74c03fcb45bfd63105a4
6
+ metadata.gz: 3751e6555921c15f8ce82f08f3c53456a3faf9b280bf7c4fce3238df42d72a3c8353721b313819b110718310592783e898c11b3b3c0cdc9357656d37c67c747b
7
+ data.tar.gz: 2bce23f9e4c874be7d065dd0d1f60623624ee60d1f87f557b2d0f7cb77bd49fcd1eb5f2361b1b65db7681ccee048efd8afbf2f756070e4a46f90b5367fc8306a
data/README.markdown CHANGED
@@ -153,9 +153,9 @@ connection.get("/users/#{id}")
153
153
 
154
154
  All forms above ave valid and will make a request to the same URL.
155
155
 
156
- * Please take note that _the endpoint can be given as a String, a Symbol, or an Array._
157
- * While they do no harm, there is _no need to pass leading or trailing `/` in endpoints._
158
- * When passing the endpoint as an Array, _it's elements are converted to Strings and concatenated with `/`._
156
+ * Please take note that _the endpoint can be given as a String, a Symbol, or an Array._
157
+ * While they do no harm, there is _no need to pass leading or trailing `/` in endpoints._
158
+ * When passing the endpoint as an Array, _it's elements are converted to Strings and concatenated with `/`._
159
159
 
160
160
  #### Optional request parameters
161
161
 
@@ -185,7 +185,7 @@ connection.post(
185
185
 
186
186
  #### Basic auth
187
187
 
188
- In case you need to use an API that is protected by **basic_auth** just pass the credentials as optional parameters:
188
+ In case you need to use an API that is protected by **basic_auth** just pass the credentials as optional parameters:
189
189
  `username: 'admin', password: 'secret'`
190
190
 
191
191
  #### Timeout duration
@@ -355,6 +355,7 @@ The error classes and their corresponding http error codes:
355
355
  RedirectionError # 301, 302, 303, 307
356
356
  BadRequestError # 400
357
357
  UnauthorizedError # 401
358
+ PaymentRequiredError # 402
358
359
  ForbiddenError # 403
359
360
  NotFoundError # 404
360
361
  MethodNotAllowedError # 405
@@ -70,6 +70,7 @@ module ChimeraHttpClient
70
70
  class RedirectionError < Error; end # 301, 302, 303, 307
71
71
  class BadRequestError < Error; end # 400
72
72
  class UnauthorizedError < Error; end # 401
73
+ class PaymentRequiredError < Error; end # 402
73
74
  class ForbiddenError < Error; end # 403
74
75
  class NotFoundError < Error; end # 404
75
76
  class MethodNotAllowedError < Error; end # 405
@@ -93,6 +93,8 @@ module ChimeraHttpClient
93
93
  BadRequestError.new(response, @options)
94
94
  when 401
95
95
  UnauthorizedError.new(response, @options)
96
+ when 402
97
+ PaymentRequiredError.new(response, @options)
96
98
  when 403
97
99
  ForbiddenError.new(response, @options)
98
100
  when 404
@@ -1,3 +1,3 @@
1
1
  module ChimeraHttpClient
2
- VERSION = "1.5.0".freeze
2
+ VERSION = "1.5.1".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chimera_http_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 1.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andreas Finger
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-05-27 00:00:00.000000000 Z
11
+ date: 2021-10-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus