quaderno 1.14.0 → 1.15.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +56 -0
- data/.rspec +2 -0
- data/.travis.yml +4 -0
- data/Gemfile +2 -15
- data/README.md +1 -1
- data/Rakefile +4 -50
- data/changelog.md +9 -0
- data/lib/quaderno-ruby.rb +3 -4
- data/lib/quaderno-ruby/base.rb +106 -108
- data/lib/quaderno-ruby/behavior/block.rb +17 -19
- data/lib/quaderno-ruby/behavior/crud.rb +93 -95
- data/lib/quaderno-ruby/behavior/deliver.rb +16 -18
- data/lib/quaderno-ruby/behavior/payment.rb +32 -34
- data/lib/quaderno-ruby/behavior/retrieve.rb +23 -25
- data/lib/quaderno-ruby/contact.rb +6 -8
- data/lib/quaderno-ruby/credit.rb +10 -12
- data/lib/quaderno-ruby/document_item.rb +1 -3
- data/lib/quaderno-ruby/estimate.rb +5 -7
- data/lib/quaderno-ruby/evidence.rb +5 -7
- data/lib/quaderno-ruby/exceptions/exceptions.rb +42 -44
- data/lib/quaderno-ruby/expense.rb +6 -8
- data/lib/quaderno-ruby/helpers/authentication.rb +16 -18
- data/lib/quaderno-ruby/income.rb +8 -10
- data/lib/quaderno-ruby/invoice.rb +9 -11
- data/lib/quaderno-ruby/item.rb +3 -6
- data/lib/quaderno-ruby/payment.rb +1 -3
- data/lib/quaderno-ruby/receipt.rb +6 -8
- data/lib/quaderno-ruby/recurring.rb +4 -7
- data/lib/quaderno-ruby/report.rb +56 -58
- data/lib/quaderno-ruby/tax.rb +45 -47
- data/lib/quaderno-ruby/version.rb +3 -0
- data/lib/quaderno-ruby/webhook.rb +3 -5
- data/quaderno.gemspec +28 -148
- metadata +83 -84
- data/Gemfile.lock +0 -91
- data/VERSION +0 -1
- data/test/fixtures/quaderno_cassettes/.DS_Store +0 -0
- data/test/fixtures/quaderno_cassettes/all_contacts.yml +0 -52
- data/test/fixtures/quaderno_cassettes/all_contacts_by_access_token.yml +0 -56
- data/test/fixtures/quaderno_cassettes/all_contacts_by_authentication_token.yml +0 -57
- data/test/fixtures/quaderno_cassettes/all_estimates.yml +0 -52
- data/test/fixtures/quaderno_cassettes/all_expenses.yml +0 -55
- data/test/fixtures/quaderno_cassettes/all_invoices.yml +0 -56
- data/test/fixtures/quaderno_cassettes/all_items.yml +0 -46
- data/test/fixtures/quaderno_cassettes/all_receipts.yml +0 -53
- data/test/fixtures/quaderno_cassettes/all_webhooks.yml +0 -214
- data/test/fixtures/quaderno_cassettes/create_estimate_on_downgraded_API.yml +0 -156
- data/test/fixtures/quaderno_cassettes/create_expense_on_downgraded_API.yml +0 -278
- data/test/fixtures/quaderno_cassettes/create_invoice_on_downgraded_API.yml +0 -159
- data/test/fixtures/quaderno_cassettes/create_receipt_on_downgraded_API.yml +0 -196
- data/test/fixtures/quaderno_cassettes/deleted_contact.yml +0 -187
- data/test/fixtures/quaderno_cassettes/deleted_contact_by_access_token.yml +0 -199
- data/test/fixtures/quaderno_cassettes/deleted_contact_by_authentication_token.yml +0 -199
- data/test/fixtures/quaderno_cassettes/deleted_estimate.yml +0 -187
- data/test/fixtures/quaderno_cassettes/deleted_expense.yml +0 -189
- data/test/fixtures/quaderno_cassettes/deleted_invoice.yml +0 -190
- data/test/fixtures/quaderno_cassettes/deleted_item.yml +0 -128
- data/test/fixtures/quaderno_cassettes/deleted_receipt.yml +0 -223
- data/test/fixtures/quaderno_cassettes/deleted_webhook.yml +0 -257
- data/test/fixtures/quaderno_cassettes/delivered_estimate.yml +0 -136
- data/test/fixtures/quaderno_cassettes/delivered_invoice.yml +0 -143
- data/test/fixtures/quaderno_cassettes/delivered_receipt.yml +0 -140
- data/test/fixtures/quaderno_cassettes/evidence_invoice.yml +0 -98
- data/test/fixtures/quaderno_cassettes/found_contact.yml +0 -95
- data/test/fixtures/quaderno_cassettes/found_contact_by_access_token.yml +0 -99
- data/test/fixtures/quaderno_cassettes/found_contact_by_authentication_token.yml +0 -100
- data/test/fixtures/quaderno_cassettes/found_estimate.yml +0 -97
- data/test/fixtures/quaderno_cassettes/found_expense.yml +0 -99
- data/test/fixtures/quaderno_cassettes/found_invoice.yml +0 -100
- data/test/fixtures/quaderno_cassettes/found_item.yml +0 -91
- data/test/fixtures/quaderno_cassettes/found_receipt.yml +0 -98
- data/test/fixtures/quaderno_cassettes/found_webhook.yml +0 -130
- data/test/fixtures/quaderno_cassettes/new_contact.yml +0 -48
- data/test/fixtures/quaderno_cassettes/new_contact_by_access_token.yml +0 -48
- data/test/fixtures/quaderno_cassettes/new_contact_by_authentication_token.yml +0 -48
- data/test/fixtures/quaderno_cassettes/new_estimate.yml +0 -137
- data/test/fixtures/quaderno_cassettes/new_evidence.yml +0 -48
- data/test/fixtures/quaderno_cassettes/new_expense.yml +0 -189
- data/test/fixtures/quaderno_cassettes/new_invoice.yml +0 -137
- data/test/fixtures/quaderno_cassettes/new_item.yml +0 -48
- data/test/fixtures/quaderno_cassettes/new_receipt.yml +0 -173
- data/test/fixtures/quaderno_cassettes/new_webhook.yml +0 -87
- data/test/fixtures/quaderno_cassettes/paid_expense.yml +0 -98
- data/test/fixtures/quaderno_cassettes/paid_invoice.yml +0 -99
- data/test/fixtures/quaderno_cassettes/rate_limit.yml +0 -46
- data/test/fixtures/quaderno_cassettes/unpay_an_expense.yml +0 -138
- data/test/fixtures/quaderno_cassettes/unpay_an_invoice.yml +0 -138
- data/test/fixtures/quaderno_cassettes/updated_contact.yml +0 -97
- data/test/fixtures/quaderno_cassettes/updated_contact_by_access_token.yml +0 -101
- data/test/fixtures/quaderno_cassettes/updated_contact_by_authentication_token.yml +0 -102
- data/test/fixtures/quaderno_cassettes/updated_estimate.yml +0 -185
- data/test/fixtures/quaderno_cassettes/updated_expense.yml +0 -184
- data/test/fixtures/quaderno_cassettes/updated_invoice.yml +0 -184
- data/test/fixtures/quaderno_cassettes/updated_item.yml +0 -93
- data/test/fixtures/quaderno_cassettes/updated_receipt.yml +0 -220
- data/test/fixtures/quaderno_cassettes/updated_webhook.yml +0 -175
- data/test/fixtures/quaderno_cassettes/validate_invalid_VAT_number.yml +0 -44
- data/test/fixtures/quaderno_cassettes/validate_valid_VAT_number.yml +0 -44
- data/test/helper.rb +0 -32
- data/test/unit/test_quaderno_contacts.rb +0 -83
- data/test/unit/test_quaderno_contacts_thread_safe.rb +0 -104
- data/test/unit/test_quaderno_estimates.rb +0 -155
- data/test/unit/test_quaderno_evidences.rb +0 -41
- data/test/unit/test_quaderno_expenses.rb +0 -162
- data/test/unit/test_quaderno_invoices.rb +0 -177
- data/test/unit/test_quaderno_items.rb +0 -84
- data/test/unit/test_quaderno_receipts.rb +0 -156
- data/test/unit/test_quaderno_tax.rb +0 -46
- data/test/unit/test_quaderno_webhooks.rb +0 -93
@@ -1,257 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: '{"url":"http://google.com","events_types":["invoice.created","expense.updated"]}'
|
9
|
-
headers:
|
10
|
-
accept:
|
11
|
-
- application/json
|
12
|
-
content-type:
|
13
|
-
- application/json
|
14
|
-
authorization:
|
15
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 201
|
19
|
-
message: Created
|
20
|
-
headers:
|
21
|
-
x-frame-options:
|
22
|
-
- ALLOWALL
|
23
|
-
x-ratelimit-limit:
|
24
|
-
- '2000'
|
25
|
-
x-ratelimit-reset:
|
26
|
-
- '9'
|
27
|
-
x-ratelimit-remaining:
|
28
|
-
- '97'
|
29
|
-
content-type:
|
30
|
-
- application/json; charset=utf-8
|
31
|
-
etag:
|
32
|
-
- '"9ed2c299de9bfb455be4f92f91a751bb"'
|
33
|
-
cache-control:
|
34
|
-
- max-age=0, private, must-revalidate
|
35
|
-
x-request-id:
|
36
|
-
- 56b4d038-9c97-4faf-bcf1-c0146ed2282e
|
37
|
-
x-runtime:
|
38
|
-
- '1.133878'
|
39
|
-
connection:
|
40
|
-
- close
|
41
|
-
server:
|
42
|
-
- thin
|
43
|
-
body:
|
44
|
-
encoding: UTF-8
|
45
|
-
string: '{"id":3,"url":"http://google.com","auth_key":"NGSLi-ewU_9MkUjNFA8H6g","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:54:14.841Z","updated_at":"2017-06-12T11:54:14.841Z"}'
|
46
|
-
http_version: '1.1'
|
47
|
-
recorded_at: Mon, 12 Jun 2017 11:54:15 GMT
|
48
|
-
- request:
|
49
|
-
method: post
|
50
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json
|
51
|
-
body:
|
52
|
-
encoding: UTF-8
|
53
|
-
string: '{"url":"http://quadernoapp.com","events_types":["invoice.created","expense.updated"]}'
|
54
|
-
headers:
|
55
|
-
accept:
|
56
|
-
- application/json
|
57
|
-
content-type:
|
58
|
-
- application/json
|
59
|
-
authorization:
|
60
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
61
|
-
response:
|
62
|
-
status:
|
63
|
-
code: 201
|
64
|
-
message: Created
|
65
|
-
headers:
|
66
|
-
x-frame-options:
|
67
|
-
- ALLOWALL
|
68
|
-
x-ratelimit-limit:
|
69
|
-
- '2000'
|
70
|
-
x-ratelimit-reset:
|
71
|
-
- '7'
|
72
|
-
x-ratelimit-remaining:
|
73
|
-
- '96'
|
74
|
-
content-type:
|
75
|
-
- application/json; charset=utf-8
|
76
|
-
etag:
|
77
|
-
- '"efc1e4c767dae7155fd7062f869b6864"'
|
78
|
-
cache-control:
|
79
|
-
- max-age=0, private, must-revalidate
|
80
|
-
x-request-id:
|
81
|
-
- fb379d20-89c7-4f44-b03a-8218e8ba6876
|
82
|
-
x-runtime:
|
83
|
-
- '1.651680'
|
84
|
-
connection:
|
85
|
-
- close
|
86
|
-
server:
|
87
|
-
- thin
|
88
|
-
body:
|
89
|
-
encoding: UTF-8
|
90
|
-
string: '{"id":4,"url":"http://quadernoapp.com","auth_key":"PPhqTNGnksKmkLIE-HN12w","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:54:16.816Z","updated_at":"2017-06-12T11:54:16.816Z"}'
|
91
|
-
http_version: '1.1'
|
92
|
-
recorded_at: Mon, 12 Jun 2017 11:54:17 GMT
|
93
|
-
- request:
|
94
|
-
method: get
|
95
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json?
|
96
|
-
body:
|
97
|
-
encoding: US-ASCII
|
98
|
-
string: ''
|
99
|
-
headers:
|
100
|
-
accept:
|
101
|
-
- application/json
|
102
|
-
authorization:
|
103
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
104
|
-
response:
|
105
|
-
status:
|
106
|
-
code: 200
|
107
|
-
message: OK
|
108
|
-
headers:
|
109
|
-
x-frame-options:
|
110
|
-
- ALLOWALL
|
111
|
-
x-ratelimit-limit:
|
112
|
-
- '2000'
|
113
|
-
x-ratelimit-reset:
|
114
|
-
- '5'
|
115
|
-
x-ratelimit-remaining:
|
116
|
-
- '95'
|
117
|
-
content-type:
|
118
|
-
- application/json; charset=utf-8
|
119
|
-
etag:
|
120
|
-
- '"7724af66c58f04bb8d43b34af89cbeb0"'
|
121
|
-
cache-control:
|
122
|
-
- max-age=0, private, must-revalidate
|
123
|
-
x-request-id:
|
124
|
-
- a83a42c7-1de0-4f2a-85ef-e98d38079d83
|
125
|
-
x-runtime:
|
126
|
-
- '0.967519'
|
127
|
-
connection:
|
128
|
-
- close
|
129
|
-
server:
|
130
|
-
- thin
|
131
|
-
body:
|
132
|
-
encoding: UTF-8
|
133
|
-
string: '[{"id":1,"url":"http://quadernoapp.com","auth_key":"Ze024XpO9CJ6Fy2frwWV4Q","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:53:54.000Z","updated_at":"2017-06-12T11:53:54.000Z"},{"id":3,"url":"http://google.com","auth_key":"NGSLi-ewU_9MkUjNFA8H6g","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:54:14.000Z","updated_at":"2017-06-12T11:54:14.000Z"},{"id":4,"url":"http://quadernoapp.com","auth_key":"PPhqTNGnksKmkLIE-HN12w","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:54:16.000Z","updated_at":"2017-06-12T11:54:16.000Z"}]'
|
134
|
-
http_version: '1.1'
|
135
|
-
recorded_at: Mon, 12 Jun 2017 11:54:18 GMT
|
136
|
-
- request:
|
137
|
-
method: delete
|
138
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks/4.json
|
139
|
-
body:
|
140
|
-
encoding: US-ASCII
|
141
|
-
string: ''
|
142
|
-
headers:
|
143
|
-
accept:
|
144
|
-
- application/json
|
145
|
-
authorization:
|
146
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
147
|
-
response:
|
148
|
-
status:
|
149
|
-
code: 204
|
150
|
-
message: No Content
|
151
|
-
headers:
|
152
|
-
x-frame-options:
|
153
|
-
- ALLOWALL
|
154
|
-
x-ratelimit-limit:
|
155
|
-
- '2000'
|
156
|
-
x-ratelimit-reset:
|
157
|
-
- '4'
|
158
|
-
x-ratelimit-remaining:
|
159
|
-
- '94'
|
160
|
-
cache-control:
|
161
|
-
- no-cache
|
162
|
-
x-request-id:
|
163
|
-
- d9d2a591-b3e2-4ba2-af85-e6d5fa634e46
|
164
|
-
x-runtime:
|
165
|
-
- '0.969496'
|
166
|
-
connection:
|
167
|
-
- close
|
168
|
-
server:
|
169
|
-
- thin
|
170
|
-
body:
|
171
|
-
encoding: US-ASCII
|
172
|
-
string: ''
|
173
|
-
http_version: '1.1'
|
174
|
-
recorded_at: Mon, 12 Jun 2017 11:54:19 GMT
|
175
|
-
- request:
|
176
|
-
method: get
|
177
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json?
|
178
|
-
body:
|
179
|
-
encoding: US-ASCII
|
180
|
-
string: ''
|
181
|
-
headers:
|
182
|
-
accept:
|
183
|
-
- application/json
|
184
|
-
authorization:
|
185
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
186
|
-
response:
|
187
|
-
status:
|
188
|
-
code: 200
|
189
|
-
message: OK
|
190
|
-
headers:
|
191
|
-
x-frame-options:
|
192
|
-
- ALLOWALL
|
193
|
-
x-ratelimit-limit:
|
194
|
-
- '2000'
|
195
|
-
x-ratelimit-reset:
|
196
|
-
- '3'
|
197
|
-
x-ratelimit-remaining:
|
198
|
-
- '93'
|
199
|
-
content-type:
|
200
|
-
- application/json; charset=utf-8
|
201
|
-
etag:
|
202
|
-
- '"49b2fb709af079dc34bb5ae479d17052"'
|
203
|
-
cache-control:
|
204
|
-
- max-age=0, private, must-revalidate
|
205
|
-
x-request-id:
|
206
|
-
- b43f132e-1500-4cfa-87cf-d76232257163
|
207
|
-
x-runtime:
|
208
|
-
- '0.938838'
|
209
|
-
connection:
|
210
|
-
- close
|
211
|
-
server:
|
212
|
-
- thin
|
213
|
-
body:
|
214
|
-
encoding: UTF-8
|
215
|
-
string: '[{"id":1,"url":"http://quadernoapp.com","auth_key":"Ze024XpO9CJ6Fy2frwWV4Q","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:53:54.000Z","updated_at":"2017-06-12T11:53:54.000Z"},{"id":3,"url":"http://google.com","auth_key":"NGSLi-ewU_9MkUjNFA8H6g","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2017-06-12T11:54:14.000Z","updated_at":"2017-06-12T11:54:14.000Z"}]'
|
216
|
-
http_version: '1.1'
|
217
|
-
recorded_at: Mon, 12 Jun 2017 11:54:20 GMT
|
218
|
-
- request:
|
219
|
-
method: delete
|
220
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks/3.json
|
221
|
-
body:
|
222
|
-
encoding: US-ASCII
|
223
|
-
string: ''
|
224
|
-
headers:
|
225
|
-
accept:
|
226
|
-
- application/json
|
227
|
-
authorization:
|
228
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
229
|
-
response:
|
230
|
-
status:
|
231
|
-
code: 204
|
232
|
-
message: No Content
|
233
|
-
headers:
|
234
|
-
x-frame-options:
|
235
|
-
- ALLOWALL
|
236
|
-
x-ratelimit-limit:
|
237
|
-
- '2000'
|
238
|
-
x-ratelimit-reset:
|
239
|
-
- '3'
|
240
|
-
x-ratelimit-remaining:
|
241
|
-
- '92'
|
242
|
-
cache-control:
|
243
|
-
- no-cache
|
244
|
-
x-request-id:
|
245
|
-
- 4ace2036-ebde-4c54-a6ba-92e9fe57c39c
|
246
|
-
x-runtime:
|
247
|
-
- '0.948995'
|
248
|
-
connection:
|
249
|
-
- close
|
250
|
-
server:
|
251
|
-
- thin
|
252
|
-
body:
|
253
|
-
encoding: US-ASCII
|
254
|
-
string: ''
|
255
|
-
http_version: '1.1'
|
256
|
-
recorded_at: Mon, 12 Jun 2017 11:54:21 GMT
|
257
|
-
recorded_with: VCR 2.9.2
|
@@ -1,136 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: get
|
5
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/estimates.json?
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
accept:
|
11
|
-
- application/json
|
12
|
-
authorization:
|
13
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
14
|
-
response:
|
15
|
-
status:
|
16
|
-
code: 200
|
17
|
-
message: OK
|
18
|
-
headers:
|
19
|
-
x-frame-options:
|
20
|
-
- ALLOWALL
|
21
|
-
x-ratelimit-limit:
|
22
|
-
- '2000'
|
23
|
-
x-ratelimit-reset:
|
24
|
-
- '15'
|
25
|
-
x-ratelimit-remaining:
|
26
|
-
- '100'
|
27
|
-
x-pages-currentpage:
|
28
|
-
- '1'
|
29
|
-
x-pages-totalpages:
|
30
|
-
- '1'
|
31
|
-
content-type:
|
32
|
-
- application/json; charset=utf-8
|
33
|
-
etag:
|
34
|
-
- '"b1aa095a3d37cb3a66bdf93f658ff2ee"'
|
35
|
-
cache-control:
|
36
|
-
- max-age=0, private, must-revalidate
|
37
|
-
x-request-id:
|
38
|
-
- 4b668b53-4776-45f0-b6f3-515e65e9a5d4
|
39
|
-
x-runtime:
|
40
|
-
- '0.395275'
|
41
|
-
connection:
|
42
|
-
- close
|
43
|
-
server:
|
44
|
-
- thin
|
45
|
-
body:
|
46
|
-
encoding: UTF-8
|
47
|
-
string: '[{"id":175,"number":"0001","issue_date":"2017-06-09","created_at":1497013347,"contact":{"id":42,"full_name":"Cidi
|
48
|
-
Campidocti"},"country":"ES","street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","items":[{"id":176,"description":"Something","quantity":"1.0","unit_price_cents":"2000.0","discount_rate":"0.0","tax_1_name":"IVA","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"2000.0","discount_cents":"0.0","gross_amount":"2000.0"}],"subtotal_cents":"2000.0","discount_cents":"0.0","taxes":[{"label":"IVA
|
49
|
-
(21.00%)","amount_cents":420}],"total_cents":2420,"payment_details":null,"notes":null,"state":"outstanding","tag_list":[],"secure_id":"f2f35a037263fe1d78a94ca62ffa1b768e8e16c6","permalink":"http://development.lvh.me:3000/estimate/f2f35a037263fe1d78a94ca62ffa1b768e8e16c6","url":"http://development.lvh.me:3000/api/estimates/175.json","custom_metadata":{}}]'
|
50
|
-
http_version: '1.1'
|
51
|
-
recorded_at: Fri, 09 Jun 2017 13:06:24 GMT
|
52
|
-
- request:
|
53
|
-
method: get
|
54
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/ping.json
|
55
|
-
body:
|
56
|
-
encoding: US-ASCII
|
57
|
-
string: ''
|
58
|
-
headers:
|
59
|
-
accept:
|
60
|
-
- application/json
|
61
|
-
authorization:
|
62
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
63
|
-
response:
|
64
|
-
status:
|
65
|
-
code: 200
|
66
|
-
message: OK
|
67
|
-
headers:
|
68
|
-
x-frame-options:
|
69
|
-
- ALLOWALL
|
70
|
-
x-ratelimit-limit:
|
71
|
-
- '2000'
|
72
|
-
x-ratelimit-reset:
|
73
|
-
- '15'
|
74
|
-
x-ratelimit-remaining:
|
75
|
-
- '99'
|
76
|
-
content-type:
|
77
|
-
- application/json; charset=utf-8
|
78
|
-
etag:
|
79
|
-
- '"0c776997933eb60833b37beaf43814c8"'
|
80
|
-
cache-control:
|
81
|
-
- max-age=0, private, must-revalidate
|
82
|
-
x-request-id:
|
83
|
-
- 90fc57c3-a86a-48e5-8045-5b7024ff5a67
|
84
|
-
x-runtime:
|
85
|
-
- '0.166282'
|
86
|
-
connection:
|
87
|
-
- close
|
88
|
-
server:
|
89
|
-
- thin
|
90
|
-
body:
|
91
|
-
encoding: UTF-8
|
92
|
-
string: '{"status":"OK"}'
|
93
|
-
http_version: '1.1'
|
94
|
-
recorded_at: Fri, 09 Jun 2017 13:06:24 GMT
|
95
|
-
- request:
|
96
|
-
method: get
|
97
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/estimates/175/deliver.json
|
98
|
-
body:
|
99
|
-
encoding: US-ASCII
|
100
|
-
string: ''
|
101
|
-
headers:
|
102
|
-
accept:
|
103
|
-
- application/json
|
104
|
-
authorization:
|
105
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
106
|
-
response:
|
107
|
-
status:
|
108
|
-
code: 422
|
109
|
-
message: Unprocessable Entity
|
110
|
-
headers:
|
111
|
-
x-frame-options:
|
112
|
-
- ALLOWALL
|
113
|
-
x-ratelimit-limit:
|
114
|
-
- '2000'
|
115
|
-
x-ratelimit-reset:
|
116
|
-
- '14'
|
117
|
-
x-ratelimit-remaining:
|
118
|
-
- '98'
|
119
|
-
content-type:
|
120
|
-
- application/json; charset=utf-8
|
121
|
-
cache-control:
|
122
|
-
- no-cache
|
123
|
-
x-request-id:
|
124
|
-
- 69f5b9c7-d537-4660-97a4-bbd07df6f0eb
|
125
|
-
x-runtime:
|
126
|
-
- '0.308794'
|
127
|
-
connection:
|
128
|
-
- close
|
129
|
-
server:
|
130
|
-
- thin
|
131
|
-
body:
|
132
|
-
encoding: UTF-8
|
133
|
-
string: '{"delivery_recipients":["can''t be blank","is invalid"]}'
|
134
|
-
http_version: '1.1'
|
135
|
-
recorded_at: Fri, 09 Jun 2017 13:06:24 GMT
|
136
|
-
recorded_with: VCR 2.9.2
|
@@ -1,143 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: get
|
5
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/invoices.json?
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
accept:
|
11
|
-
- application/json
|
12
|
-
authorization:
|
13
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
14
|
-
response:
|
15
|
-
status:
|
16
|
-
code: 200
|
17
|
-
message: OK
|
18
|
-
headers:
|
19
|
-
x-frame-options:
|
20
|
-
- ALLOWALL
|
21
|
-
x-ratelimit-limit:
|
22
|
-
- '2000'
|
23
|
-
x-ratelimit-reset:
|
24
|
-
- '10'
|
25
|
-
x-ratelimit-remaining:
|
26
|
-
- '98'
|
27
|
-
x-pages-currentpage:
|
28
|
-
- '1'
|
29
|
-
x-pages-totalpages:
|
30
|
-
- '1'
|
31
|
-
content-type:
|
32
|
-
- application/json; charset=utf-8
|
33
|
-
etag:
|
34
|
-
- '"47582ab138340fc16e49091c677bd6a5"'
|
35
|
-
cache-control:
|
36
|
-
- max-age=0, private, must-revalidate
|
37
|
-
x-request-id:
|
38
|
-
- 532d6271-81fe-42c4-b773-42c0a857f764
|
39
|
-
x-runtime:
|
40
|
-
- '4.151245'
|
41
|
-
connection:
|
42
|
-
- close
|
43
|
-
server:
|
44
|
-
- thin
|
45
|
-
body:
|
46
|
-
encoding: UTF-8
|
47
|
-
string: '[{"id":180,"blocked":false,"number":"0005","issue_date":"2017-06-09","created_at":1497013624,"contact":{"id":44,"full_name":"Albus
|
48
|
-
Dumbledoge"},"country":"BE","street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"due_date":null,"currency":"EUR","subject":null,"items":[{"id":181,"description":"Aircraft","quantity":"1.0","unit_price_cents":"0.0","discount_rate":"0.0","tax_1_name":null,"tax_1_rate":null,"tax_2_name":null,"tax_2_rate":null,"reference":null,"subtotal_cents":"0.0","discount_cents":"0.0","gross_amount_cents":"0.0"}],"subtotal_cents":"0.0","discount_cents":"0.0","taxes":[],"total_cents":0,"payments":[{"id":45,"date":"2017-06-12","payment_method":"cash","amount_cents":10000000000,"url":"http://development.lvh.me:3000/api/invoices/180/payments/45.json"}],"payment_details":null,"notes":null,"state":"paid","tag_list":[],"secure_id":"8ba033c910a376319e4b383de66d6934abcfe6a4","permalink":"http://development.lvh.me:3000/invoice/8ba033c910a376319e4b383de66d6934abcfe6a4","pdf":"http://development.lvh.me:3000/invoice/8ba033c910a376319e4b383de66d6934abcfe6a4.pdf","url":"http://development.lvh.me:3000/api/invoices/180.json","processor":null,"processor_id":null,"custom_metadata":{}},{"id":167,"blocked":true,"number":"0004","issue_date":"2017-06-07","created_at":1496825417,"contact":{"id":43,"full_name":"Test_OCP"},"country":"ES","street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"due_date":null,"currency":"EUR","subject":null,"items":[{"id":168,"description":"Something","quantity":"1.0","unit_price_cents":"1212.0","discount_rate":"0.0","tax_1_name":"IVA","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":null,"subtotal_cents":"1212.0","discount_cents":"0.0","gross_amount_cents":"1212.0"}],"subtotal_cents":"1212.0","discount_cents":"0.0","taxes":[{"label":"IVA
|
49
|
-
(21.00%)","amount_cents":254}],"total_cents":1466,"payments":[{"id":36,"date":"2017-06-07","payment_method":"wire_transfer","amount_cents":1466,"url":"http://development.lvh.me:3000/api/invoices/167/payments/36.json"}],"payment_details":null,"notes":null,"state":"paid","tag_list":[],"secure_id":"5ee4e6d22a4d8b6798a9df315395fe05a5efb80a","permalink":"http://development.lvh.me:3000/invoice/5ee4e6d22a4d8b6798a9df315395fe05a5efb80a","pdf":"http://development.lvh.me:3000/invoice/5ee4e6d22a4d8b6798a9df315395fe05a5efb80a.pdf","url":"http://development.lvh.me:3000/api/invoices/167.json","processor":null,"processor_id":null,"custom_metadata":{}},{"id":168,"blocked":false,"number":"0003","issue_date":"2017-06-07","created_at":1496825418,"contact":{"id":43,"full_name":"Test_OCP"},"country":"ES","street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"due_date":null,"currency":"EUR","subject":null,"items":[{"id":169,"description":"Something","quantity":"1.0","unit_price_cents":"671.0","discount_rate":"0.0","tax_1_name":"IVA","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":null,"subtotal_cents":"671.0","discount_cents":"0.0","gross_amount_cents":"671.0"}],"subtotal_cents":"671.0","discount_cents":"0.0","taxes":[{"label":"IVA
|
50
|
-
(21.00%)","amount_cents":141}],"total_cents":812,"payments":[],"payment_details":null,"notes":null,"state":"outstanding","tag_list":[],"secure_id":"e93f8543031ccee4aa6933b7418dbe8736ec4306","permalink":"http://development.lvh.me:3000/invoice/e93f8543031ccee4aa6933b7418dbe8736ec4306","pdf":"http://development.lvh.me:3000/invoice/e93f8543031ccee4aa6933b7418dbe8736ec4306.pdf","url":"http://development.lvh.me:3000/api/invoices/168.json","processor":null,"processor_id":null,"custom_metadata":{}},{"id":169,"blocked":false,"number":"0002","issue_date":"2017-06-07","created_at":1496825419,"contact":{"id":42,"full_name":"Cidi
|
51
|
-
Campidocti"},"country":"ES","street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"due_date":null,"currency":"EUR","subject":null,"items":[{"id":170,"description":"Something","quantity":"1.0","unit_price_cents":"2008.0","discount_rate":"0.0","tax_1_name":"IVA","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":null,"subtotal_cents":"2008.0","discount_cents":"0.0","gross_amount_cents":"2008.0"}],"subtotal_cents":"2008.0","discount_cents":"0.0","taxes":[{"label":"IVA
|
52
|
-
(21.00%)","amount_cents":422}],"total_cents":2430,"payments":[{"id":38,"date":"2017-06-07","payment_method":"wire_transfer","amount_cents":2430,"url":"http://development.lvh.me:3000/api/invoices/169/payments/38.json"}],"payment_details":null,"notes":null,"state":"paid","tag_list":[],"secure_id":"45652c45cc01d96ac603b0484e4e00754ba091c8","permalink":"http://development.lvh.me:3000/invoice/45652c45cc01d96ac603b0484e4e00754ba091c8","pdf":"http://development.lvh.me:3000/invoice/45652c45cc01d96ac603b0484e4e00754ba091c8.pdf","url":"http://development.lvh.me:3000/api/invoices/169.json","processor":null,"processor_id":null,"custom_metadata":{}},{"id":170,"blocked":false,"number":"0001","issue_date":"2017-06-07","created_at":1496825420,"contact":{"id":44,"full_name":"Albus
|
53
|
-
Dumbledoge"},"country":"BE","street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"due_date":null,"currency":"EUR","subject":null,"items":[{"id":171,"description":"Something","quantity":"1.0","unit_price_cents":"1340.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":null,"subtotal_cents":"1340.0","discount_cents":"0.0","gross_amount_cents":"1340.0"}],"subtotal_cents":"1340.0","discount_cents":"0.0","taxes":[],"total_cents":1340,"payments":[{"id":39,"date":"2017-06-07","payment_method":"wire_transfer","amount_cents":1340,"url":"http://development.lvh.me:3000/api/invoices/170/payments/39.json"}],"payment_details":null,"notes":null,"state":"paid","tag_list":[],"secure_id":"696d7d7e402f544a839e84f3328801547f6c7c12","permalink":"http://development.lvh.me:3000/invoice/696d7d7e402f544a839e84f3328801547f6c7c12","pdf":"http://development.lvh.me:3000/invoice/696d7d7e402f544a839e84f3328801547f6c7c12.pdf","url":"http://development.lvh.me:3000/api/invoices/170.json","processor":"stripe","processor_id":"ch_1234","custom_metadata":{}}]'
|
54
|
-
http_version: '1.1'
|
55
|
-
recorded_at: Mon, 12 Jun 2017 11:44:35 GMT
|
56
|
-
- request:
|
57
|
-
method: get
|
58
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/ping.json
|
59
|
-
body:
|
60
|
-
encoding: US-ASCII
|
61
|
-
string: ''
|
62
|
-
headers:
|
63
|
-
accept:
|
64
|
-
- application/json
|
65
|
-
authorization:
|
66
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
67
|
-
response:
|
68
|
-
status:
|
69
|
-
code: 200
|
70
|
-
message: OK
|
71
|
-
headers:
|
72
|
-
x-frame-options:
|
73
|
-
- ALLOWALL
|
74
|
-
x-ratelimit-limit:
|
75
|
-
- '2000'
|
76
|
-
x-ratelimit-reset:
|
77
|
-
- '6'
|
78
|
-
x-ratelimit-remaining:
|
79
|
-
- '97'
|
80
|
-
content-type:
|
81
|
-
- application/json; charset=utf-8
|
82
|
-
etag:
|
83
|
-
- '"0c776997933eb60833b37beaf43814c8"'
|
84
|
-
cache-control:
|
85
|
-
- max-age=0, private, must-revalidate
|
86
|
-
x-request-id:
|
87
|
-
- 3f3848ed-e7b0-4d1e-b816-3de7870a1b85
|
88
|
-
x-runtime:
|
89
|
-
- '0.841116'
|
90
|
-
connection:
|
91
|
-
- close
|
92
|
-
server:
|
93
|
-
- thin
|
94
|
-
body:
|
95
|
-
encoding: UTF-8
|
96
|
-
string: '{"status":"OK"}'
|
97
|
-
http_version: '1.1'
|
98
|
-
recorded_at: Mon, 12 Jun 2017 11:44:36 GMT
|
99
|
-
- request:
|
100
|
-
method: get
|
101
|
-
uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/invoices/180/deliver.json
|
102
|
-
body:
|
103
|
-
encoding: US-ASCII
|
104
|
-
string: ''
|
105
|
-
headers:
|
106
|
-
accept:
|
107
|
-
- application/json
|
108
|
-
authorization:
|
109
|
-
- Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
|
110
|
-
response:
|
111
|
-
status:
|
112
|
-
code: 200
|
113
|
-
message: OK
|
114
|
-
headers:
|
115
|
-
x-frame-options:
|
116
|
-
- ALLOWALL
|
117
|
-
x-ratelimit-limit:
|
118
|
-
- '2000'
|
119
|
-
x-ratelimit-reset:
|
120
|
-
- '5'
|
121
|
-
x-ratelimit-remaining:
|
122
|
-
- '96'
|
123
|
-
content-type:
|
124
|
-
- application/json; charset=utf-8
|
125
|
-
etag:
|
126
|
-
- '"074a3d2686ff1d99dbf981e8328f05ae"'
|
127
|
-
cache-control:
|
128
|
-
- max-age=0, private, must-revalidate
|
129
|
-
x-request-id:
|
130
|
-
- bc4d1421-eaf5-44ba-b068-729c7f663b92
|
131
|
-
x-runtime:
|
132
|
-
- '2.232292'
|
133
|
-
connection:
|
134
|
-
- close
|
135
|
-
server:
|
136
|
-
- thin
|
137
|
-
body:
|
138
|
-
encoding: UTF-8
|
139
|
-
string: '{"id":180,"account_id":9,"contact_id":44,"document_id":null,"number":"0005","issue_date":"2017-06-09","contact_name":"Albus
|
140
|
-
Dumbledoge","currency":"EUR","gross_amount_cents":0,"total_cents":0,"amount_paid_cents":10000000000,"exchange_rate":"1.0","exchange_cents":null,"po_number":null,"due_days":null,"due_date":null,"valid_until":null,"payment_details":null,"notes":null,"permalink":"8ba033c910a376319e4b383de66d6934abcfe6a4","recurring_document":null,"start_date":null,"end_date":null,"renewal_date":null,"frequency":null,"delivery":null,"state":"paid","created_at":"2017-06-09T13:07:04.000Z","updated_at":"2017-06-12T11:44:38.213Z","attachments_count":0,"processor_id":null,"subject":null,"transaction_id":null,"street_line_1":null,"street_line_2":null,"city":null,"postal_code":null,"region":null,"country":"BE","processor":null,"processor_fee_cents":null,"interval_count":0,"delivery_state":"delivered","vat_number":null,"tax_id":null,"metadata":{},"blocked":false}'
|
141
|
-
http_version: '1.1'
|
142
|
-
recorded_at: Mon, 12 Jun 2017 11:44:38 GMT
|
143
|
-
recorded_with: VCR 2.9.2
|