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 +4 -4
- data/README.markdown +5 -4
- data/lib/chimera_http_client/error.rb +1 -0
- data/lib/chimera_http_client/request.rb +2 -0
- data/lib/chimera_http_client/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e14b26c79080837393064bdccc64a6bb4f994d4938258480b264eebf06136cf2
|
4
|
+
data.tar.gz: 42e0af5e1ac6aa1dd6adeb67b10d51c050ea239d9065c81be674b8b120337f88
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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
|
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.
|
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-
|
11
|
+
date: 2021-10-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|