easybill-api 0.7.2 → 0.7.3
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 +4 -4
- data/README.md +2 -2
- data/lib/easybill/api/response_handler.rb +5 -5
- data/lib/easybill/api/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d313b1b589635a884cdd4485bdd9288d704357a0
|
|
4
|
+
data.tar.gz: 49089e0728f600694e9714d0671d248dbea65a8c
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 23e9366bf430a4d7a7b43c08474f841d74a794a677b188511914c7d1b675c4331eec253c93ac63428c5b3a8804deaa850850136d4671cc5479d0f50c119cbbd9
|
|
7
|
+
data.tar.gz: 64476f6b154bbf25735fa5a11e7237c24d26cb8d11aa866c14d724bd679183d139e483afa41544f017be6f5c21e7c7a1d9e49d853a8ef31499a47dad03955233
|
data/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Easybill::Api
|
|
2
2
|
|
|
3
|
-
This is the ruby wrapper for the easybill REST Api
|
|
3
|
+
This is the ruby wrapper for the easybill REST Api.
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
@@ -23,7 +23,7 @@ Or install it yourself as:
|
|
|
23
23
|
Initialize a new api client:
|
|
24
24
|
|
|
25
25
|
```
|
|
26
|
-
@api = Easybill::Api.new(<YOUR API TOKEN>)
|
|
26
|
+
@api = Easybill::Api::Client.new(<YOUR API TOKEN>)
|
|
27
27
|
```
|
|
28
28
|
|
|
29
29
|
Example calls based on the `customers` resource:
|
|
@@ -11,15 +11,15 @@ module Easybill
|
|
|
11
11
|
when 200..299
|
|
12
12
|
response
|
|
13
13
|
when 400
|
|
14
|
-
raise Easybill::Errors::BadRequestError, response.
|
|
14
|
+
raise Easybill::Errors::BadRequestError, response.body
|
|
15
15
|
when 401
|
|
16
|
-
raise Easybill::Errors::NotAuthorizedError, response.
|
|
16
|
+
raise Easybill::Errors::NotAuthorizedError, response.body
|
|
17
17
|
when 404
|
|
18
|
-
raise Easybill::Errors::ResourceNotFoundError, response.
|
|
18
|
+
raise Easybill::Errors::ResourceNotFoundError, response.body
|
|
19
19
|
when 429
|
|
20
|
-
raise Easybill::Errors::RateLimitExceededError, response.
|
|
20
|
+
raise Easybill::Errors::RateLimitExceededError, response.body
|
|
21
21
|
when 500...600
|
|
22
|
-
raise Easybill::Errors::ServerError, "Failed with: #{response.code} #{response.
|
|
22
|
+
raise Easybill::Errors::ServerError, "Failed with: #{response.code} #{response.body}"
|
|
23
23
|
end
|
|
24
24
|
end
|
|
25
25
|
end
|
data/lib/easybill/api/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: easybill-api
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.7.
|
|
4
|
+
version: 0.7.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Patrick Schnetger
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2016-
|
|
11
|
+
date: 2016-10-21 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|