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
@@ -1,99 +1,89 @@
1
1
  ---
2
2
  http_interactions:
3
3
  - request:
4
- method: get
5
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/items.json
4
+ method: post
5
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/items.json
6
6
  body:
7
- encoding: US-ASCII
8
- string: ''
7
+ encoding: UTF-8
8
+ string: code=1466681270&name=Test_Skynet&unit_cost=21.0
9
9
  headers:
10
+ accept:
11
+ - application/json
10
12
  authorization:
11
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
13
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
12
14
  response:
13
15
  status:
14
- code: 200
15
- message: OK
16
+ code: 201
17
+ message: Created
16
18
  headers:
17
- server:
18
- - nginx/1.4.5
19
- date:
20
- - Tue, 01 Jul 2014 09:08:04 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
+ - '3'
31
25
  x-ratelimit-remaining:
32
- - '1928'
33
- x-ua-compatible:
34
- - IE=Edge,chrome=1
26
+ - '90'
27
+ content-type:
28
+ - application/json; charset=utf-8
35
29
  etag:
36
- - ! '"484111898eb77f3321009a9c45671d7c"'
30
+ - '"2b1d7621e76538bd066381618cc88d7d"'
37
31
  cache-control:
38
- - must-revalidate, private, max-age=0
32
+ - max-age=0, private, must-revalidate
39
33
  x-request-id:
40
- - 20973c55031c616436cdc86a46b93e77
34
+ - a7415359-5206-4e36-aa3e-cdc1adc5d82f
41
35
  x-runtime:
42
- - '0.048222'
43
- x-rack-cache:
44
- - miss
36
+ - '0.640244'
37
+ connection:
38
+ - close
39
+ server:
40
+ - thin
45
41
  body:
46
- encoding: US-ASCII
47
- string: ! '[{"id":23943,"code":"008","name":"Pizza the Hutt","unit_cost":"0.0","stock":null,"url":"http://uruk-1066.sandbox-quadernoapp.com/api/v1/items/23943"},{"id":23942,"code":"007","name":"Techtoys
48
- MechaGodzilla 13cm fully posable","unit_cost":"0.0","stock":null,"url":"http://uruk-1066.sandbox-quadernoapp.com/api/v1/items/23942"}]'
42
+ encoding: UTF-8
43
+ string: '{"id":12,"code":"1466681270","name":"Test_Skynet","unit_cost":"21.0","stock":null,"url":"http://development.lvh.me:3000/api/items/12"}'
49
44
  http_version: '1.1'
50
- recorded_at: Tue, 01 Jul 2014 09:08:04 GMT
45
+ recorded_at: Thu, 23 Jun 2016 11:27:51 GMT
51
46
  - request:
52
47
  method: get
53
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/items/23942.json
48
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/items/12.json
54
49
  body:
55
50
  encoding: US-ASCII
56
51
  string: ''
57
52
  headers:
53
+ accept:
54
+ - application/json
58
55
  authorization:
59
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
56
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
60
57
  response:
61
58
  status:
62
59
  code: 200
63
60
  message: OK
64
61
  headers:
65
- server:
66
- - nginx/1.4.5
67
- date:
68
- - Tue, 01 Jul 2014 09:08:04 GMT
69
- content-type:
70
- - application/json; charset=utf-8
71
- transfer-encoding:
72
- - chunked
73
- connection:
74
- - close
75
- status:
76
- - 200 OK
62
+ x-frame-options:
63
+ - ALLOWALL
77
64
  x-ratelimit-limit:
78
65
  - '2000'
66
+ x-ratelimit-reset:
67
+ - '2'
79
68
  x-ratelimit-remaining:
80
- - '1927'
81
- last-modified:
82
- - Tue, 01 Jul 2014 08:44:41 GMT
69
+ - '89'
70
+ content-type:
71
+ - application/json; charset=utf-8
72
+ etag:
73
+ - '"2b1d7621e76538bd066381618cc88d7d"'
83
74
  cache-control:
84
- - must-revalidate, private, max-age=0
85
- x-ua-compatible:
86
- - IE=Edge,chrome=1
75
+ - max-age=0, private, must-revalidate
87
76
  x-request-id:
88
- - acba7f550e6217a8afb8065be96f5948
77
+ - 319d4d17-475f-4ce1-8e76-6b40f8707a48
89
78
  x-runtime:
90
- - '0.062193'
91
- x-rack-cache:
92
- - miss
79
+ - '0.637247'
80
+ connection:
81
+ - close
82
+ server:
83
+ - thin
93
84
  body:
94
- encoding: US-ASCII
95
- string: ! '{"id":23942,"code":"007","name":"Techtoys MechaGodzilla 13cm fully
96
- posable","unit_cost":"0.0","stock":null,"url":"http://uruk-1066.sandbox-quadernoapp.com/api/v1/items/23942"}'
85
+ encoding: UTF-8
86
+ string: '{"id":12,"code":"1466681270","name":"Test_Skynet","unit_cost":"21.0","stock":null,"url":"http://development.lvh.me:3000/api/items/12"}'
97
87
  http_version: '1.1'
98
- recorded_at: Tue, 01 Jul 2014 09:08:05 GMT
88
+ recorded_at: Thu, 23 Jun 2016 11:27:52 GMT
99
89
  recorded_with: VCR 2.9.2
@@ -0,0 +1,101 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/receipts.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
+ - '"b3b66954c987c74b8ebbdba19fda50af"'
35
+ cache-control:
36
+ - max-age=0, private, must-revalidate
37
+ x-request-id:
38
+ - af63ad5f-f655-415c-b757-1c41ba287d75
39
+ x-runtime:
40
+ - '1.035304'
41
+ connection:
42
+ - close
43
+ server:
44
+ - thin
45
+ body:
46
+ encoding: UTF-8
47
+ string: '[{"id":1056,"number":"0000005","issue_date":"2016-06-23","created_at":1466680696,"contact":{"id":85,"full_name":"Test
48
+ customer"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","exchange_rate":"1.9558","items":[{"id":3075,"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":[],"payments":[{"id":27,"date":"2016-06-23","payment_method":"cash","amount_cents":0}],"notes":"Show
49
+ me the moneeeeeeeyy!!!!","state":"paid","tag_list":[],"secure_id":"24c7be97cfdae58052852e11a7df8f5968f90e06","permalink":"http://development.lvh.me:3000/receipt/24c7be97cfdae58052852e11a7df8f5968f90e06","pdf":"http://development.lvh.me:3000/receipt/24c7be97cfdae58052852e11a7df8f5968f90e06.pdf","url":"http://development.lvh.me:3000/api/receipts/1056.json","processor":null,"processor_id":null},{"id":1055,"number":"0000004","issue_date":"2016-06-23","created_at":1466680690,"contact":{"id":84,"full_name":"Test
50
+ customer"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","exchange_rate":"1.9558","items":[{"id":3074,"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":[],"payments":[{"id":26,"date":"2016-06-23","payment_method":"cash","amount_cents":0}],"notes":null,"state":"paid","tag_list":[],"secure_id":"2e21a8451f234c2a673d3576f178faab516ec017","permalink":"http://development.lvh.me:3000/receipt/2e21a8451f234c2a673d3576f178faab516ec017","pdf":"http://development.lvh.me:3000/receipt/2e21a8451f234c2a673d3576f178faab516ec017.pdf","url":"http://development.lvh.me:3000/api/receipts/1055.json","processor":null,"processor_id":null},{"id":1054,"number":"0000003","issue_date":"2016-06-23","created_at":1466680679,"contact":{"id":82,"full_name":"Test
51
+ customer"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","exchange_rate":"1.9558","items":[{"id":3073,"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":[],"payments":[{"id":25,"date":"2016-06-23","payment_method":"cash","amount_cents":0}],"notes":null,"state":"paid","tag_list":[],"secure_id":"80ff611baa512d72f5132b28feacce20997adb4e","permalink":"http://development.lvh.me:3000/receipt/80ff611baa512d72f5132b28feacce20997adb4e","pdf":"http://development.lvh.me:3000/receipt/80ff611baa512d72f5132b28feacce20997adb4e.pdf","url":"http://development.lvh.me:3000/api/receipts/1054.json","processor":null,"processor_id":null},{"id":985,"number":"0000002","issue_date":"2016-06-01","created_at":1464785121,"contact":{"id":56,"full_name":"William
52
+ Tell"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","exchange_rate":"1.0","items":[{"id":991,"description":"Something","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":[],"payments":[{"id":4,"date":"2016-06-01","payment_method":"credit_card","amount_cents":0}],"notes":null,"state":"invoiced","tag_list":[],"secure_id":"885fc61e0b83f9d507fcbb6fa9495ba0dcc31d96","permalink":"http://development.lvh.me:3000/receipt/885fc61e0b83f9d507fcbb6fa9495ba0dcc31d96","pdf":"http://development.lvh.me:3000/receipt/885fc61e0b83f9d507fcbb6fa9495ba0dcc31d96.pdf","url":"http://development.lvh.me:3000/api/receipts/985.json","processor":null,"processor_id":null},{"id":983,"number":"0000001","issue_date":"2016-05-30","created_at":1464785067,"contact":{"id":52,"full_name":"A.
53
+ Lucas Mayoral"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","exchange_rate":"1.0","items":[{"id":989,"description":"Something","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":[],"payments":[{"id":2,"date":"2016-05-30","payment_method":"credit_card","amount_cents":0}],"notes":null,"state":"invoiced","tag_list":[],"secure_id":"9d00a9c881965f04758c4d5627c38cc8d4182713","permalink":"http://development.lvh.me:3000/receipt/9d00a9c881965f04758c4d5627c38cc8d4182713","pdf":"http://development.lvh.me:3000/receipt/9d00a9c881965f04758c4d5627c38cc8d4182713.pdf","url":"http://development.lvh.me:3000/api/receipts/983.json","processor":null,"processor_id":null}]'
54
+ http_version: '1.1'
55
+ recorded_at: Thu, 23 Jun 2016 11:28:10 GMT
56
+ - request:
57
+ method: get
58
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/receipts/1056.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
+ - '15'
78
+ x-ratelimit-remaining:
79
+ - '99'
80
+ content-type:
81
+ - application/json; charset=utf-8
82
+ etag:
83
+ - '"6e98e167256652e39b10c61fa70cad98"'
84
+ cache-control:
85
+ - max-age=0, private, must-revalidate
86
+ x-request-id:
87
+ - 40077033-54da-42b0-b635-760121559d5b
88
+ x-runtime:
89
+ - '0.595983'
90
+ connection:
91
+ - close
92
+ server:
93
+ - thin
94
+ body:
95
+ encoding: UTF-8
96
+ string: '{"id":1056,"number":"0000005","issue_date":"2016-06-23","created_at":1466680696,"contact":{"id":85,"full_name":"Test
97
+ customer"},"street_line_1":null,"street_line_2":null,"city":null,"region":null,"postal_code":null,"po_number":null,"currency":"EUR","exchange_rate":"1.9558","items":[{"id":3075,"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":[],"payments":[{"id":27,"date":"2016-06-23","payment_method":"cash","amount_cents":0}],"notes":"Show
98
+ me the moneeeeeeeyy!!!!","state":"paid","tag_list":[],"secure_id":"24c7be97cfdae58052852e11a7df8f5968f90e06","permalink":"http://development.lvh.me:3000/receipt/24c7be97cfdae58052852e11a7df8f5968f90e06","pdf":"http://development.lvh.me:3000/receipt/24c7be97cfdae58052852e11a7df8f5968f90e06.pdf","url":"http://development.lvh.me:3000/api/receipts/1056.json","processor":null,"processor_id":null}'
99
+ http_version: '1.1'
100
+ recorded_at: Thu, 23 Jun 2016 11:28:10 GMT
101
+ recorded_with: VCR 2.9.2
@@ -2,143 +2,127 @@
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%2Fquadernoapp.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:27 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
+ - '13'
31
25
  x-ratelimit-remaining:
32
- - '1915'
33
- x-ua-compatible:
34
- - IE=Edge,chrome=1
26
+ - '96'
27
+ content-type:
28
+ - application/json; charset=utf-8
35
29
  etag:
36
- - ! '"4b88bcffebbd7c3046c9b16ce59b08f6"'
30
+ - '"1597f2571353f1573969bf6b8b0e3cdf"'
37
31
  cache-control:
38
32
  - max-age=0, private, must-revalidate
39
- set-cookie:
40
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJTMzNWQ3YTI5MmVkNjc4YjBhNWYyZjY2MGU2ZDEyMmYyBjsAVA%3D%3D--1d98a8c1310fb79a6f4d3626811c0ece4f9a071c;
41
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
42
33
  x-request-id:
43
- - ae83502397d1e6a67412ff12aaa4b3bc
34
+ - 11f09934-aab7-40b6-ae1b-3f937ebb8896
44
35
  x-runtime:
45
- - '0.385142'
46
- x-rack-cache:
47
- - invalidate, pass
36
+ - '10.094418'
37
+ connection:
38
+ - close
39
+ server:
40
+ - thin
48
41
  body:
49
- encoding: US-ASCII
50
- string: ! '{"id":88,"url":"http://quadernoapp.com","auth_key":"hEgs5t6arWRvLNCJMVTjfA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:27Z","updated_at":"2014-07-01T09:08:27Z"}'
42
+ encoding: UTF-8
43
+ string: '{"id":32,"url":"http://quadernoapp.com","auth_key":"_3oUDCHa7C2A5YgaCIi6VA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:29:03.895Z","updated_at":"2016-06-23T11:29:03.895Z"}'
51
44
  http_version: '1.1'
52
- recorded_at: Tue, 01 Jul 2014 09:08:27 GMT
45
+ recorded_at: Thu, 23 Jun 2016 11:29:04 GMT
53
46
  - request:
54
47
  method: get
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
50
  encoding: US-ASCII
58
51
  string: ''
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: 200
65
60
  message: OK
66
61
  headers:
67
- server:
68
- - nginx/1.4.5
69
- date:
70
- - Tue, 01 Jul 2014 09:08:28 GMT
71
- content-type:
72
- - application/json; charset=utf-8
73
- transfer-encoding:
74
- - chunked
75
- connection:
76
- - close
77
- status:
78
- - 200 OK
62
+ x-frame-options:
63
+ - ALLOWALL
79
64
  x-ratelimit-limit:
80
65
  - '2000'
66
+ x-ratelimit-reset:
67
+ - '3'
81
68
  x-ratelimit-remaining:
82
- - '1914'
83
- x-ua-compatible:
84
- - IE=Edge,chrome=1
69
+ - '95'
70
+ content-type:
71
+ - application/json; charset=utf-8
85
72
  etag:
86
- - ! '"2785c64822a65472545183ad74bd67ed"'
73
+ - '"e1275952d50c8a538ea728a8ca6bb3e7"'
87
74
  cache-control:
88
- - must-revalidate, private, max-age=0
75
+ - max-age=0, private, must-revalidate
89
76
  x-request-id:
90
- - 1053cc4c1db3d54a91b1d45e1859323d
77
+ - 2e175fc4-9c07-4939-9fae-0602557c8643
91
78
  x-runtime:
92
- - '0.076984'
93
- x-rack-cache:
94
- - miss
79
+ - '0.671506'
80
+ connection:
81
+ - close
82
+ server:
83
+ - thin
95
84
  body:
96
- encoding: US-ASCII
97
- string: ! '[{"id":88,"url":"http://quadernoapp.com","auth_key":"hEgs5t6arWRvLNCJMVTjfA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2014-07-01T09:08:27Z","updated_at":"2014-07-01T09:08:27Z"}]'
85
+ encoding: UTF-8
86
+ string: '[{"id":32,"url":"http://quadernoapp.com","auth_key":"_3oUDCHa7C2A5YgaCIi6VA","events_types":["invoice.created","expense.updated"],"last_sent_at":null,"last_error":null,"events_sent":0,"created_at":"2016-06-23T11:29:03.000Z","updated_at":"2016-06-23T11:29:03.000Z"}]'
98
87
  http_version: '1.1'
99
- recorded_at: Tue, 01 Jul 2014 09:08:28 GMT
88
+ recorded_at: Thu, 23 Jun 2016 11:29:04 GMT
100
89
  - request:
101
90
  method: delete
102
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/webhooks/88.json
91
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/webhooks/32.json
103
92
  body:
104
93
  encoding: US-ASCII
105
94
  string: ''
106
95
  headers:
96
+ accept:
97
+ - application/json
107
98
  authorization:
108
- - Basic UnNOYUxzTnIxS1pjZHJRUktLS2s6
99
+ - Basic c2tfdGVzdF9CN3hYclRzcGZlR3VrUXFHTjFwSzo=
109
100
  response:
110
101
  status:
111
102
  code: 204
112
103
  message: No Content
113
104
  headers:
114
- server:
115
- - nginx/1.4.5
116
- date:
117
- - Tue, 01 Jul 2014 09:08:28 GMT
118
- connection:
119
- - close
120
- status:
121
- - 204 No Content
105
+ x-frame-options:
106
+ - ALLOWALL
122
107
  x-ratelimit-limit:
123
108
  - '2000'
109
+ x-ratelimit-reset:
110
+ - '2'
124
111
  x-ratelimit-remaining:
125
- - '1913'
126
- x-ua-compatible:
127
- - IE=Edge,chrome=1
112
+ - '94'
128
113
  cache-control:
129
114
  - no-cache
130
- set-cookie:
131
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJWFiNTExZDE1Mzc4OWRhMmMzZDdhMmRmMWFhZTU0NjAyBjsAVA%3D%3D--2d0fe7e54971040d34e575f56f43451becc09b86;
132
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
133
115
  x-request-id:
134
- - 8d3b945095f20a74f839f9cdc6cbde88
116
+ - 0eb46fef-6e29-43fc-8be0-fc2277bc5f4a
135
117
  x-runtime:
136
- - '0.043856'
137
- x-rack-cache:
138
- - invalidate, pass
118
+ - '0.419223'
119
+ connection:
120
+ - close
121
+ server:
122
+ - thin
139
123
  body:
140
124
  encoding: US-ASCII
141
125
  string: ''
142
126
  http_version: '1.1'
143
- recorded_at: Tue, 01 Jul 2014 09:08:28 GMT
127
+ recorded_at: Thu, 23 Jun 2016 11:29:05 GMT
144
128
  recorded_with: VCR 2.9.2
@@ -2,52 +2,45 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://RsNaLsNr1KZcdrQRKKKk@uruk-1066.sandbox-quadernoapp.com/api/v1/contacts.json
5
+ uri: http://sk_test_B7xXrTspfeGukQqGN1pK@development.lvh.me:3000/api/contacts.json
6
6
  body:
7
- encoding: US-ASCII
7
+ encoding: UTF-8
8
8
  string: kind=company&first_name=Test_Skynet&email=my_little%40po.ny
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:05:48 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
- - '1999'
33
- x-ua-compatible:
34
- - IE=Edge,chrome=1
26
+ - '99'
27
+ content-type:
28
+ - application/json; charset=utf-8
35
29
  etag:
36
- - ! '"5c3a053e216a9cd1b8bc3301f9caa4e7"'
30
+ - '"4d92dd7f465d302daeb8b6eaaa7d099b"'
37
31
  cache-control:
38
32
  - max-age=0, private, must-revalidate
39
- set-cookie:
40
- - _quaderno_session=BAh7BkkiD3Nlc3Npb25faWQGOgZFVEkiJWJhMjk5OTM0OGFkZTgwNDI3ZWFiZTk3MTMxNjk4MzM3BjsAVA%3D%3D--e8c8435ced0e6770b4db1565f2115a94cdda60b7;
41
- domain=sandbox-quadernoapp.com; path=/; HttpOnly
42
33
  x-request-id:
43
- - 7983944cdcd9a35df1f7c436ea2301e9
34
+ - 72f200bf-4e70-409c-8ccc-2b62e5bf4d92
44
35
  x-runtime:
45
- - '0.138948'
46
- x-rack-cache:
47
- - invalidate, pass
36
+ - '3.015393'
37
+ connection:
38
+ - close
39
+ server:
40
+ - thin
48
41
  body:
49
- encoding: US-ASCII
50
- string: ! '{"id":142303,"kind":"company","full_name":"Test_Skynet","contact_name":null,"street_line_1":null,"street_line_2":null,"postal_code":null,"city":null,"region":null,"country":"US","phone_1":null,"phone_2":null,"fax":null,"email":"my_little@po.ny","web":null,"discount":null,"tax_id":null,"language":"EN","notes":null,"url":"http://uruk-1066.sandbox-quadernoapp.com/api/v1/contacts/142303"}'
42
+ encoding: UTF-8
43
+ string: '{"id":86,"kind":"company","created_at":1466681108,"full_name":"Test_Skynet","contact_name":null,"street_line_1":null,"street_line_2":null,"postal_code":null,"city":null,"region":null,"country":"ES","phone_1":null,"phone_2":null,"fax":null,"email":"my_little@po.ny","web":null,"discount":null,"tax_id":null,"vat_number":null,"bank_account":null,"language":"ES","notes":null,"secure_id":"17bbf9fb5e227af4bdb792fbda7050d914cceebf","permalink":"http://development.lvh.me:3000/billing/17bbf9fb5e227af4bdb792fbda7050d914cceebf","url":"http://development.lvh.me:3000/api/contacts/86"}'
51
44
  http_version: '1.1'
52
- recorded_at: Tue, 01 Jul 2014 09:05:48 GMT
45
+ recorded_at: Thu, 23 Jun 2016 11:25:10 GMT
53
46
  recorded_with: VCR 2.9.2