quaderno 1.9.1 → 1.9.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +6 -6
  3. data/Gemfile.lock +8 -5
  4. data/README.md +7 -1
  5. data/VERSION +1 -1
  6. data/changelog.md +5 -0
  7. data/lib/quaderno-ruby/behavior/crud.rb +30 -36
  8. data/lib/quaderno-ruby/behavior/payment.rb +12 -19
  9. data/lib/quaderno-ruby/behavior/retrieve.rb +20 -0
  10. data/lib/quaderno-ruby/contact.rb +1 -0
  11. data/lib/quaderno-ruby/payment.rb +0 -2
  12. data/lib/quaderno-ruby/tax.rb +3 -3
  13. data/lib/quaderno-ruby/webhook.rb +0 -2
  14. data/lib/quaderno-ruby.rb +1 -1
  15. data/quaderno.gemspec +15 -3
  16. data/test/fixtures/quaderno_cassettes/all_contacts.yml +295 -31
  17. data/test/fixtures/quaderno_cassettes/all_estimates.yml +28 -36
  18. data/test/fixtures/quaderno_cassettes/all_expenses.yml +60 -34
  19. data/test/fixtures/quaderno_cassettes/all_invoices.yml +2888 -36
  20. data/test/fixtures/quaderno_cassettes/all_items.yml +22 -27
  21. data/test/fixtures/quaderno_cassettes/all_receipts.yml +56 -0
  22. data/test/fixtures/quaderno_cassettes/all_webhooks.yml +98 -126
  23. data/test/fixtures/quaderno_cassettes/calculate_tax.yml +38 -62
  24. data/test/fixtures/quaderno_cassettes/create_estimate_on_downgraded_API.yml +428 -0
  25. data/test/fixtures/quaderno_cassettes/create_expense_on_downgraded_API.yml +510 -0
  26. data/test/fixtures/quaderno_cassettes/create_invoice_on_downgraded_API.yml +432 -0
  27. data/test/fixtures/quaderno_cassettes/create_receipt_on_downgraded_API.yml +193 -0
  28. data/test/fixtures/quaderno_cassettes/deleted_contact.yml +642 -113
  29. data/test/fixtures/quaderno_cassettes/deleted_estimate.yml +385 -120
  30. data/test/fixtures/quaderno_cassettes/deleted_expense.yml +414 -118
  31. data/test/fixtures/quaderno_cassettes/deleted_invoice.yml +3249 -120
  32. data/test/fixtures/quaderno_cassettes/deleted_item.yml +60 -75
  33. data/test/fixtures/quaderno_cassettes/deleted_receipt.yml +222 -0
  34. data/test/fixtures/quaderno_cassettes/deleted_webhook.yml +120 -152
  35. data/test/fixtures/quaderno_cassettes/delivered_estimate.yml +76 -89
  36. data/test/fixtures/quaderno_cassettes/delivered_invoice.yml +2935 -89
  37. data/test/fixtures/quaderno_cassettes/delivered_receipt.yml +140 -0
  38. data/test/fixtures/quaderno_cassettes/found_contact.yml +319 -60
  39. data/test/fixtures/quaderno_cassettes/found_estimate.yml +53 -69
  40. data/test/fixtures/quaderno_cassettes/found_expense.yml +121 -65
  41. data/test/fixtures/quaderno_cassettes/found_invoice.yml +2916 -67
  42. data/test/fixtures/quaderno_cassettes/found_item.yml +50 -60
  43. data/test/fixtures/quaderno_cassettes/found_receipt.yml +101 -0
  44. data/test/fixtures/quaderno_cassettes/found_webhook.yml +60 -76
  45. data/test/fixtures/quaderno_cassettes/new_contact.yml +22 -29
  46. data/test/fixtures/quaderno_cassettes/new_estimate.yml +357 -84
  47. data/test/fixtures/quaderno_cassettes/new_expense.yml +414 -118
  48. data/test/fixtures/quaderno_cassettes/new_invoice.yml +361 -84
  49. data/test/fixtures/quaderno_cassettes/new_item.yml +22 -29
  50. data/test/fixtures/quaderno_cassettes/new_receipt.yml +169 -0
  51. data/test/fixtures/quaderno_cassettes/new_webhook.yml +38 -50
  52. data/test/fixtures/quaderno_cassettes/paid_expense.yml +79 -63
  53. data/test/fixtures/quaderno_cassettes/paid_invoice.yml +2907 -65
  54. data/test/fixtures/quaderno_cassettes/rate_limit.yml +22 -26
  55. data/test/fixtures/quaderno_cassettes/unpay_an_expense.yml +98 -85
  56. data/test/fixtures/quaderno_cassettes/unpay_an_invoice.yml +2926 -87
  57. data/test/fixtures/quaderno_cassettes/updated_contact.yml +318 -62
  58. data/test/fixtures/quaderno_cassettes/updated_estimate.yml +402 -116
  59. data/test/fixtures/quaderno_cassettes/updated_expense.yml +395 -113
  60. data/test/fixtures/quaderno_cassettes/updated_invoice.yml +410 -116
  61. data/test/fixtures/quaderno_cassettes/updated_item.yml +49 -61
  62. data/test/fixtures/quaderno_cassettes/updated_receipt.yml +214 -0
  63. data/test/fixtures/quaderno_cassettes/updated_webhook.yml +82 -105
  64. data/test/fixtures/quaderno_cassettes/wrong_token.yml +11 -25
  65. data/test/helper.rb +4 -0
  66. data/test/unit/test_quaderno_contacts.rb +18 -19
  67. data/test/unit/test_quaderno_estimates.rb +58 -31
  68. data/test/unit/test_quaderno_expenses.rb +68 -41
  69. data/test/unit/test_quaderno_invoices.rb +74 -47
  70. data/test/unit/test_quaderno_items.rb +27 -26
  71. data/test/unit/test_quaderno_receipts.rb +156 -0
  72. data/test/unit/test_quaderno_tax.rb +10 -10
  73. data/test/unit/test_quaderno_webhooks.rb +19 -20
  74. metadata +14 -2
@@ -2,284 +2,252 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks.json
5
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json
6
6
  body:
7
- encoding: US-ASCII
7
+ encoding: UTF-8
8
8
  string: url=http%3A%2F%2Fgoogle.com&events_types[]=invoice.created&events_types[]=expense.updated
9
9
  headers:
10
+ accept:
11
+ - application/json
10
12
  authorization:
11
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
13
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
12
14
  response:
13
15
  status:
14
16
  code: 201
15
17
  message: Created
16
18
  headers:
17
- server:
18
- - nginx/1.4.5
19
- date:
20
- - Tue, 01 Jul 2014 09:08:22 GMT
21
- content-type:
22
- - application/json; charset=utf-8
23
- transfer-encoding:
24
- - chunked
25
- connection:
26
- - close
27
- status:
28
- - 201 Created
19
+ x-frame-options:
20
+ - ALLOWALL
29
21
  x-ratelimit-limit:
30
22
  - '2000'
23
+ x-ratelimit-reset:
24
+ - '15'
31
25
  x-ratelimit-remaining:
32
- - '1921'
33
- x-ua-compatible:
34
- - IE=Edge,chrome=1
26
+ - '99'
27
+ content-type:
28
+ - application/json; charset=utf-8
35
29
  etag:
36
- - ! '"04a57fa7a4726bd26a6936d199d04a1e"'
30
+ - '"92e794f6dfade79007eb6440600b7f3b"'
37
31
  cache-control:
38
32
  - max-age=0, private, must-revalidate
39
- set-cookie:
40
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJWM4NDg5YjhhZWFiOWY2MTY3M2M2N2FlMWI2MTU4MTMyBjsAVA%3D%3D--d2c9ca686e9e557657cf1df9bcf6753eb79ed37f;
41
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
42
33
  x-request-id:
43
- - c8e8c8fd20b8e1f85db894d4d6d8a9d8
34
+ - dbd50442-292f-4708-baa7-5416573abfee
44
35
  x-runtime:
45
- - '0.230042'
46
- x-rack-cache:
47
- - invalidate, pass
36
+ - '3.512932'
37
+ connection:
38
+ - close
39
+ server:
40
+ - thin
48
41
  body:
49
- encoding: US-ASCII
50
- string: ! '{"id":86,"url":"http://google.com","auth_key":"16szhYlPFBHLuf4bRYyflg","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:22Z","updated_at":"2014-07-01T09:08:22Z"}'
42
+ encoding: UTF-8
43
+ string: '{"id":30,"url":"http://google.com","auth_key":"IQGTwY6ANnp2br-uFUVArA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:28:40.362Z","updated_at":"2016-06-23T11:28:40.362Z"}'
51
44
  http_version: '1.1'
52
- recorded_at: Tue, 01 Jul 2014 09:08:22 GMT
45
+ recorded_at: Thu, 23 Jun 2016 11:28:40 GMT
53
46
  - request:
54
47
  method: post
55
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks.json
48
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json
56
49
  body:
57
- encoding: US-ASCII
50
+ encoding: UTF-8
58
51
  string: url=http%3A%2F%2Fquadernoapp.com&events_types[]=invoice.created&events_types[]=expense.updated
59
52
  headers:
53
+ accept:
54
+ - application/json
60
55
  authorization:
61
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
56
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
62
57
  response:
63
58
  status:
64
59
  code: 201
65
60
  message: Created
66
61
  headers:
67
- server:
68
- - nginx/1.4.5
69
- date:
70
- - Tue, 01 Jul 2014 09:08:23 GMT
71
- content-type:
72
- - application/json; charset=utf-8
73
- transfer-encoding:
74
- - chunked
75
- connection:
76
- - close
77
- status:
78
- - 201 Created
62
+ x-frame-options:
63
+ - ALLOWALL
79
64
  x-ratelimit-limit:
80
65
  - '2000'
66
+ x-ratelimit-reset:
67
+ - '11'
81
68
  x-ratelimit-remaining:
82
- - '1920'
83
- x-ua-compatible:
84
- - IE=Edge,chrome=1
69
+ - '98'
70
+ content-type:
71
+ - application/json; charset=utf-8
85
72
  etag:
86
- - ! '"c7ef8e71778d7d4d7208db301d01192f"'
73
+ - '"4e09e3e820e3408f8ff279ad09621e87"'
87
74
  cache-control:
88
75
  - max-age=0, private, must-revalidate
89
- set-cookie:
90
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJTg0MzI0ZmY0YWYwMjE0YWNlOWQ2NjFhNmE1NTQyMDI4BjsAVA%3D%3D--6730219651c0d504976d9a5bc3ae797354ba457e;
91
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
92
76
  x-request-id:
93
- - daafa115da016fdd991bc3716bdb2548
77
+ - 4f607ec3-4e5b-4ba0-a38b-c4dc8d550a73
94
78
  x-runtime:
95
- - '0.336793'
96
- x-rack-cache:
97
- - invalidate, pass
79
+ - '10.722992'
80
+ connection:
81
+ - close
82
+ server:
83
+ - thin
98
84
  body:
99
- encoding: US-ASCII
100
- string: ! '{"id":87,"url":"http://quadernoapp.com","auth_key":"PFFIoqK-tOgTjF0tr0tlSw","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:23Z","updated_at":"2014-07-01T09:08:23Z"}'
85
+ encoding: UTF-8
86
+ string: '{"id":31,"url":"http://quadernoapp.com","auth_key":"Ge_NQlzRFWEV_OvomIrsYw","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:28:51.035Z","updated_at":"2016-06-23T11:28:51.035Z"}'
101
87
  http_version: '1.1'
102
- recorded_at: Tue, 01 Jul 2014 09:08:23 GMT
88
+ recorded_at: Thu, 23 Jun 2016 11:28:51 GMT
103
89
  - request:
104
90
  method: get
105
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks.json
91
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json
106
92
  body:
107
93
  encoding: US-ASCII
108
94
  string: ''
109
95
  headers:
96
+ accept:
97
+ - application/json
110
98
  authorization:
111
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
99
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
112
100
  response:
113
101
  status:
114
102
  code: 200
115
103
  message: OK
116
104
  headers:
117
- server:
118
- - nginx/1.4.5
119
- date:
120
- - Tue, 01 Jul 2014 09:08:24 GMT
121
- content-type:
122
- - application/json; charset=utf-8
123
- transfer-encoding:
124
- - chunked
125
- connection:
126
- - close
127
- status:
128
- - 200 OK
105
+ x-frame-options:
106
+ - ALLOWALL
129
107
  x-ratelimit-limit:
130
108
  - '2000'
109
+ x-ratelimit-reset:
110
+ - '15'
131
111
  x-ratelimit-remaining:
132
- - '1919'
133
- x-ua-compatible:
134
- - IE=Edge,chrome=1
112
+ - '100'
113
+ content-type:
114
+ - application/json; charset=utf-8
135
115
  etag:
136
- - ! '"e108c2a8a6c719eb4bf78eb9f2b6a599"'
116
+ - '"eb898c3049b9a254d392f340aa0aeb96"'
137
117
  cache-control:
138
- - must-revalidate, private, max-age=0
118
+ - max-age=0, private, must-revalidate
139
119
  x-request-id:
140
- - 0499ee92f5f24e2cd55aa8dcacb00db6
120
+ - 2990180c-e43e-4359-a79e-6ab9f887eebb
141
121
  x-runtime:
142
- - '0.052238'
143
- x-rack-cache:
144
- - miss
122
+ - '1.324438'
123
+ connection:
124
+ - close
125
+ server:
126
+ - thin
145
127
  body:
146
- encoding: US-ASCII
147
- string: ! '[{"id":86,"url":"http://google.com","auth_key":"16szhYlPFBHLuf4bRYyflg","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:22Z","updated_at":"2014-07-01T09:08:22Z"},{"id":87,"url":"http://quadernoapp.com","auth_key":"PFFIoqK-tOgTjF0tr0tlSw","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:23Z","updated_at":"2014-07-01T09:08:23Z"}]'
128
+ encoding: UTF-8
129
+ string: '[{"id":30,"url":"http://google.com","auth_key":"IQGTwY6ANnp2br-uFUVArA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:28:40.000Z","updated_at":"2016-06-23T11:28:40.000Z"},{"id":31,"url":"http://quadernoapp.com","auth_key":"Ge_NQlzRFWEV_OvomIrsYw","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:28:51.000Z","updated_at":"2016-06-23T11:28:51.000Z"}]'
148
130
  http_version: '1.1'
149
- recorded_at: Tue, 01 Jul 2014 09:08:24 GMT
131
+ recorded_at: Thu, 23 Jun 2016 11:28:52 GMT
150
132
  - request:
151
133
  method: delete
152
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks/87.json
134
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks/31.json
153
135
  body:
154
136
  encoding: US-ASCII
155
137
  string: ''
156
138
  headers:
139
+ accept:
140
+ - application/json
157
141
  authorization:
158
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
142
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
159
143
  response:
160
144
  status:
161
145
  code: 204
162
146
  message: No Content
163
147
  headers:
164
- server:
165
- - nginx/1.4.5
166
- date:
167
- - Tue, 01 Jul 2014 09:08:24 GMT
168
- connection:
169
- - close
170
- status:
171
- - 204 No Content
148
+ x-frame-options:
149
+ - ALLOWALL
172
150
  x-ratelimit-limit:
173
151
  - '2000'
152
+ x-ratelimit-reset:
153
+ - '15'
174
154
  x-ratelimit-remaining:
175
- - '1918'
176
- x-ua-compatible:
177
- - IE=Edge,chrome=1
155
+ - '99'
178
156
  cache-control:
179
157
  - no-cache
180
- set-cookie:
181
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJTk0NDU4MzM3ZGI0YTkxMDkxMTFkZWFiMTgzODQ2NjRlBjsAVA%3D%3D--d860ea1df967bf88b5a88015ebb981018f3849ca;
182
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
183
158
  x-request-id:
184
- - 3095c16ca86f37b21679661ea7f48abb
159
+ - 6a082838-5537-42d7-b04b-991f1ef6dbfc
185
160
  x-runtime:
186
- - '0.052367'
187
- x-rack-cache:
188
- - invalidate, pass
161
+ - '0.451251'
162
+ connection:
163
+ - close
164
+ server:
165
+ - thin
189
166
  body:
190
167
  encoding: US-ASCII
191
168
  string: ''
192
169
  http_version: '1.1'
193
- recorded_at: Tue, 01 Jul 2014 09:08:24 GMT
170
+ recorded_at: Thu, 23 Jun 2016 11:28:53 GMT
194
171
  - request:
195
172
  method: get
196
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks.json
173
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks.json
197
174
  body:
198
175
  encoding: US-ASCII
199
176
  string: ''
200
177
  headers:
178
+ accept:
179
+ - application/json
201
180
  authorization:
202
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
181
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
203
182
  response:
204
183
  status:
205
184
  code: 200
206
185
  message: OK
207
186
  headers:
208
- server:
209
- - nginx/1.4.5
210
- date:
211
- - Tue, 01 Jul 2014 09:08:26 GMT
212
- content-type:
213
- - application/json; charset=utf-8
214
- transfer-encoding:
215
- - chunked
216
- connection:
217
- - close
218
- status:
219
- - 200 OK
187
+ x-frame-options:
188
+ - ALLOWALL
220
189
  x-ratelimit-limit:
221
190
  - '2000'
191
+ x-ratelimit-reset:
192
+ - '14'
222
193
  x-ratelimit-remaining:
223
- - '1917'
224
- x-ua-compatible:
225
- - IE=Edge,chrome=1
194
+ - '98'
195
+ content-type:
196
+ - application/json; charset=utf-8
226
197
  etag:
227
- - ! '"e5515d7568244fdf0ae0040b5898faf3"'
198
+ - '"9835c4543859d74bc2f2ab9a7c2d9c7e"'
228
199
  cache-control:
229
- - must-revalidate, private, max-age=0
200
+ - max-age=0, private, must-revalidate
230
201
  x-request-id:
231
- - 595835f4f4de341dbe95c713b00b0eba
202
+ - f6e3cac6-e9d1-4e3c-af0a-3a6a9af52f1a
232
203
  x-runtime:
233
- - '0.040607'
234
- x-rack-cache:
235
- - miss
204
+ - '0.339346'
205
+ connection:
206
+ - close
207
+ server:
208
+ - thin
236
209
  body:
237
- encoding: US-ASCII
238
- string: ! '[{"id":86,"url":"http://google.com","auth_key":"16szhYlPFBHLuf4bRYyflg","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:22Z","updated_at":"2014-07-01T09:08:22Z"}]'
210
+ encoding: UTF-8
211
+ string: '[{"id":30,"url":"http://google.com","auth_key":"IQGTwY6ANnp2br-uFUVArA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:28:40.000Z","updated_at":"2016-06-23T11:28:40.000Z"}]'
239
212
  http_version: '1.1'
240
- recorded_at: Tue, 01 Jul 2014 09:08:26 GMT
213
+ recorded_at: Thu, 23 Jun 2016 11:28:53 GMT
241
214
  - request:
242
215
  method: delete
243
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks/86.json
216
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks/30.json
244
217
  body:
245
218
  encoding: US-ASCII
246
219
  string: ''
247
220
  headers:
221
+ accept:
222
+ - application/json
248
223
  authorization:
249
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
224
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
250
225
  response:
251
226
  status:
252
227
  code: 204
253
228
  message: No Content
254
229
  headers:
255
- server:
256
- - nginx/1.4.5
257
- date:
258
- - Tue, 01 Jul 2014 09:08:26 GMT
259
- connection:
260
- - close
261
- status:
262
- - 204 No Content
230
+ x-frame-options:
231
+ - ALLOWALL
263
232
  x-ratelimit-limit:
264
233
  - '2000'
234
+ x-ratelimit-reset:
235
+ - '13'
265
236
  x-ratelimit-remaining:
266
- - '1916'
267
- x-ua-compatible:
268
- - IE=Edge,chrome=1
237
+ - '97'
269
238
  cache-control:
270
239
  - no-cache
271
- set-cookie:
272
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJTVjZjkwN2ZiYmE1MjM5MTcxOTYxZjRmMzQ2Mjc4NjUyBjsAVA%3D%3D--e618fbf39ca4418c6474853b499b81f362427f4e;
273
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
274
240
  x-request-id:
275
- - bee403cfb46226e7fe6b27fcf105344c
241
+ - 77992c95-93db-454d-884f-4698e47b73f5
276
242
  x-runtime:
277
- - '0.043049'
278
- x-rack-cache:
279
- - invalidate, pass
243
+ - '0.470050'
244
+ connection:
245
+ - close
246
+ server:
247
+ - thin
280
248
  body:
281
249
  encoding: US-ASCII
282
250
  string: ''
283
251
  http_version: '1.1'
284
- recorded_at: Tue, 01 Jul 2014 09:08:26 GMT
252
+ recorded_at: Thu, 23 Jun 2016 11:28:53 GMT
285
253
  recorded_with: VCR 2.9.2
@@ -2,155 +2,142 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/estimates.json
5
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/estimates.json
6
6
  body:
7
7
  encoding: US-ASCII
8
8
  string: ''
9
9
  headers:
10
+ accept:
11
+ - application/json
10
12
  authorization:
11
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
13
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
12
14
  response:
13
15
  status:
14
16
  code: 200
15
17
  message: OK
16
18
  headers:
17
- server:
18
- - nginx/1.4.5
19
- date:
20
- - Tue, 01 Jul 2014 09:06:19 GMT
21
- content-type:
22
- - application/json; charset=utf-8
23
- transfer-encoding:
24
- - chunked
25
- connection:
26
- - close
27
- status:
28
- - 200 OK
19
+ x-frame-options:
20
+ - ALLOWALL
29
21
  x-ratelimit-limit:
30
22
  - '2000'
23
+ x-ratelimit-reset:
24
+ - '13'
31
25
  x-ratelimit-remaining:
32
- - '1982'
26
+ - '98'
33
27
  x-pages-currentpage:
34
28
  - '1'
35
29
  x-pages-totalpages:
36
30
  - '1'
37
- x-ua-compatible:
38
- - IE=Edge,chrome=1
31
+ content-type:
32
+ - application/json; charset=utf-8
39
33
  etag:
40
- - ! '"d33c420455711494333dc878dbb2cf3a"'
34
+ - '"74819ab6a2b52790377d5890e49d72fa"'
41
35
  cache-control:
42
- - must-revalidate, private, max-age=0
36
+ - max-age=0, private, must-revalidate
43
37
  x-request-id:
44
- - cb3a70b88b7dc551d961e0fb1d709601
38
+ - c105d414-492d-4d11-aad8-a96ec7ea3e9f
45
39
  x-runtime:
46
- - '0.106069'
47
- x-rack-cache:
48
- - miss
40
+ - '1.116629'
41
+ connection:
42
+ - close
43
+ server:
44
+ - thin
49
45
  body:
50
- encoding: US-ASCII
51
- string: ! '[{"id":492372,"number":"0000002","issue_date":"2014-07-01","contact":{"id":142302,"full_name":"Pepe
52
- Gotera & Otilio"},"po_number":"","currency":"EUR","items":[{"id":1294890,"description":"Test
53
- Item #5","quantity":"1.0","unit_price":"52.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal":"52.00
54
- \u20ac","discount":"0.00 \u20ac","gross_amount":"52.00 \u20ac"},{"id":1294891,"description":"Test
55
- Item #6","quantity":"1.0","unit_price":"30.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal":"30.00
56
- \u20ac","discount":"0.00 \u20ac","gross_amount":"30.00 \u20ac"}],"subtotal":"82.00
57
- \u20ac","discount":"0.00 \u20ac","taxes":[],"total":"82.00 \u20ac","payment_details":"","notes":"","state":"draft","tag_list":[],"secure_id":"4cf5cf7de5fa21c0c68737db16aa8d4630d11d19","permalink":"http://uruk-1066.sandbox-quadernoapp.com/estimate/4cf5cf7de5fa21c0c68737db16aa8d4630d11d19","url":"http://uruk-1066.sandbox-quadernoapp.com/api/v1/estimates/492372.json"},{"id":492371,"number":"0000001","issue_date":"2014-07-01","contact":{"id":142302,"full_name":"Pepe
58
- Gotera & Otilio"},"po_number":"","currency":"EUR","items":[{"id":1294889,"description":"Test
59
- Item #4","quantity":"1.0","unit_price":"3430.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal":"3,430.00
60
- \u20ac","discount":"0.00 \u20ac","gross_amount":"3,430.00 \u20ac"}],"subtotal":"3,430.00
61
- \u20ac","discount":"0.00 \u20ac","taxes":[],"total":"3,430.00 \u20ac","payment_details":"","notes":"","state":"draft","tag_list":[],"secure_id":"4f635b1811bc6cc20a071fe4f85bf8733c04b451","permalink":"http://uruk-1066.sandbox-quadernoapp.com/estimate/4f635b1811bc6cc20a071fe4f85bf8733c04b451","url":"http://uruk-1066.sandbox-quadernoapp.com/api/v1/estimates/492371.json"}]'
46
+ encoding: UTF-8
47
+ string: '[{"id":999,"number":"0000003","issue_date":"2016-06-08","created_at":1465391771,"contact":{"id":58,"full_name":"Test_OCP
48
+ Diepstraten"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","items":[{"id":1012,"description":"1","quantity":"1.0","unit_price_cents":"1000.0","discount_rate":"0.0","tax_1_name":"BTW","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"1000.0","discount_cents":"0.0","gross_amount":"1000.0"},{"id":1013,"description":"2","quantity":"1.0","unit_price_cents":"1000.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"1000.0","discount_cents":"0.0","gross_amount":"1000.0"}],"subtotal_cents":"2000.0","discount_cents":"0.0","taxes":[{"label":"BTW
49
+ (21.00%)","amount_cents":210}],"total_cents":2210,"payment_details":null,"notes":null,"state":"invoiced","tag_list":[],"secure_id":"3ba0301fb141753b1a9e81f8e2e87f8e4d27436b","permalink":"http://development.lvh.me:3000/estimate/3ba0301fb141753b1a9e81f8e2e87f8e4d27436b","url":"http://development.lvh.me:3000/api/estimates/999.json"},{"id":995,"number":"0000002","issue_date":"2016-06-08","created_at":1465391049,"contact":{"id":58,"full_name":"Test_OCP
50
+ Diepstraten"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","items":[{"id":1005,"description":"1","quantity":"1.0","unit_price_cents":"1000.0","discount_rate":"0.0","tax_1_name":"BTW","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"1000.0","discount_cents":"0.0","gross_amount":"1000.0"},{"id":1006,"description":"2","quantity":"1.0","unit_price_cents":"1000.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"1000.0","discount_cents":"0.0","gross_amount":"1000.0"}],"subtotal_cents":"2000.0","discount_cents":"0.0","taxes":[{"label":"BTW
51
+ (21.00%)","amount_cents":210}],"total_cents":2210,"payment_details":null,"notes":null,"state":"invoiced","tag_list":[],"secure_id":"a95cc19fd4def0024964a8d6aedd6d24de960e3f","permalink":"http://development.lvh.me:3000/estimate/a95cc19fd4def0024964a8d6aedd6d24de960e3f","url":"http://development.lvh.me:3000/api/estimates/995.json"},{"id":992,"number":"0000001","issue_date":"2016-06-02","created_at":1464869069,"contact":{"id":58,"full_name":"Test_OCP
52
+ Diepstraten"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","items":[{"id":1000,"description":"1","quantity":"1.0","unit_price_cents":"0.0","discount_rate":"0.0","tax_1_name":"BTW","tax_1_rate":21.0,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"0.0","discount_cents":"0.0","gross_amount":"0.0"},{"id":1001,"description":"2","quantity":"1.0","unit_price_cents":"0.0","discount_rate":"0.0","tax_1_name":"","tax_1_rate":null,"tax_2_name":"","tax_2_rate":null,"reference":"","subtotal_cents":"0.0","discount_cents":"0.0","gross_amount":"0.0"}],"subtotal_cents":"0.0","discount_cents":"0.0","taxes":[{"label":"BTW
53
+ (21.00%)","amount_cents":0}],"total_cents":0,"payment_details":null,"notes":null,"state":"invoiced","tag_list":[],"secure_id":"91e361b2d900856d8e7e230b4175956d0f163162","permalink":"http://development.lvh.me:3000/estimate/91e361b2d900856d8e7e230b4175956d0f163162","url":"http://development.lvh.me:3000/api/estimates/992.json"}]'
62
54
  http_version: '1.1'
63
- recorded_at: Tue, 01 Jul 2014 09:06:19 GMT
55
+ recorded_at: Thu, 23 Jun 2016 11:25:30 GMT
64
56
  - request:
65
57
  method: get
66
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/ping.json
58
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/ping.json
67
59
  body:
68
60
  encoding: US-ASCII
69
61
  string: ''
70
62
  headers:
63
+ accept:
64
+ - application/json
71
65
  authorization:
72
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
66
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
73
67
  response:
74
68
  status:
75
69
  code: 200
76
70
  message: OK
77
71
  headers:
78
- server:
79
- - nginx/1.4.5
80
- date:
81
- - Tue, 01 Jul 2014 09:06:20 GMT
82
- content-type:
83
- - application/json; charset=utf-8
84
- transfer-encoding:
85
- - chunked
86
- connection:
87
- - close
88
- status:
89
- - 200 OK
72
+ x-frame-options:
73
+ - ALLOWALL
90
74
  x-ratelimit-limit:
91
75
  - '2000'
76
+ x-ratelimit-reset:
77
+ - '12'
92
78
  x-ratelimit-remaining:
93
- - '1982'
94
- x-ua-compatible:
95
- - IE=Edge,chrome=1
79
+ - '97'
80
+ content-type:
81
+ - application/json; charset=utf-8
96
82
  etag:
97
- - ! '"0c776997933eb60833b37beaf43814c8"'
83
+ - '"0c776997933eb60833b37beaf43814c8"'
98
84
  cache-control:
99
- - must-revalidate, private, max-age=0
85
+ - max-age=0, private, must-revalidate
100
86
  x-request-id:
101
- - 1d5cf3e513b35d08e2b5ccf37178fe5a
87
+ - 1abffd04-54f4-4238-a34b-2119e0897497
102
88
  x-runtime:
103
- - '0.023349'
104
- x-rack-cache:
105
- - miss
89
+ - '0.555849'
90
+ connection:
91
+ - close
92
+ server:
93
+ - thin
106
94
  body:
107
- encoding: US-ASCII
108
- string: ! '{"status":"OK"}'
95
+ encoding: UTF-8
96
+ string: '{"status":"OK"}'
109
97
  http_version: '1.1'
110
- recorded_at: Tue, 01 Jul 2014 09:06:20 GMT
98
+ recorded_at: Thu, 23 Jun 2016 11:25:31 GMT
111
99
  - request:
112
100
  method: get
113
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/estimates/492372/deliver.json
101
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/estimates/999/deliver.json
114
102
  body:
115
103
  encoding: US-ASCII
116
104
  string: ''
117
105
  headers:
106
+ accept:
107
+ - application/json
118
108
  authorization:
119
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
109
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
120
110
  response:
121
111
  status:
122
- code: 422
123
- message: Unprocessable Entity
112
+ code: 200
113
+ message: OK
124
114
  headers:
125
- server:
126
- - nginx/1.4.5
127
- date:
128
- - Tue, 01 Jul 2014 09:06:20 GMT
129
- content-type:
130
- - application/json; charset=utf-8
131
- transfer-encoding:
132
- - chunked
133
- connection:
134
- - close
135
- status:
136
- - 422 Unprocessable Entity
115
+ x-frame-options:
116
+ - ALLOWALL
137
117
  x-ratelimit-limit:
138
118
  - '2000'
119
+ x-ratelimit-reset:
120
+ - '12'
139
121
  x-ratelimit-remaining:
140
- - '1981'
141
- x-ua-compatible:
142
- - IE=Edge,chrome=1
122
+ - '96'
123
+ content-type:
124
+ - application/json; charset=utf-8
125
+ etag:
126
+ - '"bfa123c11b608a95baca6b72c1cea8b5"'
143
127
  cache-control:
144
- - no-cache, private
128
+ - max-age=0, private, must-revalidate
145
129
  x-request-id:
146
- - 05c3adf472dc191a4d6696eafabb13bf
130
+ - 20e8d60e-e446-4411-945c-fe94de74bdd9
147
131
  x-runtime:
148
- - '0.068573'
149
- x-rack-cache:
150
- - miss
132
+ - '1.201669'
133
+ connection:
134
+ - close
135
+ server:
136
+ - thin
151
137
  body:
152
- encoding: US-ASCII
153
- string: ! '{"delivery_recipients":["can''t be blank","is invalid"]}'
138
+ encoding: UTF-8
139
+ string: '{"id":999,"account_id":2,"contact_id":58,"document_id":null,"number":"0000003","issue_date":"2016-06-08","contact_name":"Test_OCP
140
+ Diepstraten","currency":"EUR","gross_amount_cents":2000,"total_cents":2210,"amount_paid_cents":0,"exchange_rate":"1.0","exchange_cents":2210,"po_number":null,"due_days":null,"due_date":null,"valid_until":null,"payment_details":null,"notes":null,"permalink":"3ba0301fb141753b1a9e81f8e2e87f8e4d27436b","recurring_document":null,"start_date":null,"end_date":null,"renewal_date":null,"frequency":null,"delivery":null,"state":"invoiced","created_at":"2016-06-08T13:16:11.000Z","updated_at":"2016-06-23T11:25:32.078Z","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":"NL","processor":null,"processor_fee_cents":null,"interval_count":0,"delivery_state":"delivered","vat_number":null,"tax_id":""}'
154
141
  http_version: '1.1'
155
- recorded_at: Tue, 01 Jul 2014 09:06:20 GMT
142
+ recorded_at: Thu, 23 Jun 2016 11:25:32 GMT
156
143
  recorded_with: VCR 2.9.2