recurly 0.4.2 → 0.4.3

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of recurly might be problematic. Click here for more details.

Files changed (71) hide show
  1. data/lib/recurly.rb +1 -0
  2. data/lib/recurly/base.rb +92 -12
  3. data/lib/recurly/formats/xml_with_errors.rb +132 -0
  4. data/lib/recurly/version.rb +1 -1
  5. data/spec/config/recurly.yml +4 -4
  6. data/spec/integration/transaction_spec.rb +4 -3
  7. data/spec/vcr/account/accept-language-account/1297746103.yml +6 -6
  8. data/spec/vcr/account/close/1297746103.yml +17 -17
  9. data/spec/vcr/account/create-blank/1297746103.yml +4 -4
  10. data/spec/vcr/account/create-duplicate/1297746103.yml +10 -10
  11. data/spec/vcr/account/create-min/1297746103.yml +6 -6
  12. data/spec/vcr/account/create/1297746103.yml +6 -6
  13. data/spec/vcr/account/find/1297746103.yml +16 -16
  14. data/spec/vcr/account/list/1297746103.yml +204 -156
  15. data/spec/vcr/account/update/1297746103.yml +29 -29
  16. data/spec/vcr/billing/create/1298594128.yml +21 -21
  17. data/spec/vcr/billing/destroy/1298594128.yml +28 -28
  18. data/spec/vcr/billing/find/1298594128.yml +28 -28
  19. data/spec/vcr/billing/update/1298594128.yml +29 -29
  20. data/spec/vcr/charge/create/1297746103.yml +29 -29
  21. data/spec/vcr/charge/delete-uninvoiced/1297746103.yml +32 -32
  22. data/spec/vcr/charge/list-all/1297746103.yml +41 -41
  23. data/spec/vcr/charge/list-invoiced/1297746103.yml +68 -68
  24. data/spec/vcr/charge/list-pending/1297746103.yml +41 -41
  25. data/spec/vcr/charge/lookup/1297746103.yml +21 -21
  26. data/spec/vcr/coupon/create/1299714521.yml +25 -25
  27. data/spec/vcr/coupon/destroy/1299714521.yml +22 -22
  28. data/spec/vcr/credit/create/1299714599.yml +21 -21
  29. data/spec/vcr/credit/delete/1299714599.yml +28 -28
  30. data/spec/vcr/credit/list/1299714599.yml +41 -41
  31. data/spec/vcr/credit/lookup/1299714599.yml +21 -21
  32. data/spec/vcr/invoice/create-no-charges/1297746103.yml +18 -18
  33. data/spec/vcr/invoice/create/1297746103.yml +42 -42
  34. data/spec/vcr/invoice/list/1297746103.yml +61 -61
  35. data/spec/vcr/invoice/lookup/1297746103.yml +43 -43
  36. data/spec/vcr/plan/all.yml +65 -52
  37. data/spec/vcr/plan/find.yml +58 -34
  38. data/spec/vcr/plan/update.yml +28 -29
  39. data/spec/vcr/subscription/addons/add/1297746103.yml +293 -335
  40. data/spec/vcr/subscription/addons/add/1301884213.yml +480 -0
  41. data/spec/vcr/subscription/addons/create/1297746103.yml +134 -335
  42. data/spec/vcr/subscription/addons/create/1301884213.yml +321 -0
  43. data/spec/vcr/subscription/addons/remove/1297746103.yml +262 -335
  44. data/spec/vcr/subscription/addons/remove/1301884213.yml +449 -0
  45. data/spec/vcr/subscription/cancel-with-code/{1297746103.yml → 1301881900.yml} +104 -92
  46. data/spec/vcr/subscription/cancel/{1297746103.yml → 1301881900.yml} +90 -78
  47. data/spec/vcr/subscription/change1/{1297746103.yml → 1301881900.yml} +86 -74
  48. data/spec/vcr/subscription/change2/{1297746103.yml → 1301881900.yml} +86 -74
  49. data/spec/vcr/subscription/create/{1297746103.yml → 1301881900.yml} +50 -38
  50. data/spec/vcr/subscription/find/{1297746103.yml → 1301881900.yml} +62 -50
  51. data/spec/vcr/subscription/reactivate/{1297746103.yml → 1301881900.yml} +95 -83
  52. data/spec/vcr/subscription/refund-full/{1297746103.yml → 1301881900.yml} +79 -67
  53. data/spec/vcr/subscription/refund-none/{1297746103.yml → 1301881900.yml} +79 -67
  54. data/spec/vcr/subscription/refund-partial/{1297746103.yml → 1301881900.yml} +79 -67
  55. data/spec/vcr/transaction/all/1301883347.yml +387 -0
  56. data/spec/vcr/transaction/create-no-account/{1300473500.yml → 1301883347.yml} +18 -18
  57. data/spec/vcr/transaction/create-with-account/{1300473500.yml → 1301883347.yml} +37 -37
  58. data/spec/vcr/transaction/list-filled/{1300473500.yml → 1301883347.yml} +169 -169
  59. data/spec/vcr/transaction/list-initial/{1300473500.yml → 1301883347.yml} +39 -39
  60. data/spec/vcr/transaction/lookup/{1300473500.yml → 1301883347.yml} +119 -119
  61. data/spec/vcr/transaction/refund/{1300473500.yml → 1301883347.yml} +53 -53
  62. data/spec/vcr/transaction/void/1301883347.yml +365 -0
  63. data/spec/vcr/transparent/post-url/{1300476053.yml → 1301879142.yml} +19 -19
  64. metadata +66 -58
  65. data/spec/vcr/transaction/all/1300473500.yml +0 -387
  66. data/spec/vcr/transaction/void/1300473500.yml +0 -620
  67. data/spec/vcr/transparent/post-url/1300475927.yml +0 -41
  68. data/spec/vcr/transparent/post-url/1300475952.yml +0 -41
  69. data/spec/vcr/transparent/post-url/1300476034.yml +0 -125
  70. data/spec/vcr/transparent/post-url/1300476102.yml +0 -125
  71. data/spec/vcr/transparent/post-url/1300476126.yml +0 -125
@@ -2,11 +2,11 @@
2
2
  - !ruby/struct:VCR::HTTPInteraction
3
3
  request: !ruby/struct:VCR::Request
4
4
  method: :post
5
- uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts.xml
5
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/accounts.xml
6
6
  body: |
7
7
  <?xml version="1.0" encoding="UTF-8"?>
8
8
  <account>
9
- <account-code>transaction-refund-1300473500</account-code>
9
+ <account-code>transaction-refund-1301883347</account-code>
10
10
  <first-name>Verena</first-name>
11
11
  <last-name>Test</last-name>
12
12
  <email>verena@test.com</email>
@@ -20,7 +20,7 @@
20
20
 
21
21
  headers:
22
22
  authorization:
23
- - Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
23
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
24
24
  content-type:
25
25
  - application/xml
26
26
  accept:
@@ -37,15 +37,15 @@
37
37
  cache-control:
38
38
  - no-cache
39
39
  location:
40
- - http://app.recurly.local:3000/accounts/transaction-refund-1300473500
40
+ - http://app.recurly.local:3000/accounts/transaction-refund-1301883347
41
41
  x-runtime:
42
- - "364"
42
+ - "317"
43
43
  content-type:
44
44
  - application/xml; charset=utf-8
45
45
  content-length:
46
46
  - "591"
47
47
  set-cookie:
48
- - _recurly_session=6a56af9f690ad0c4fd1450f061a8da1e; domain=.recurly.local; path=/; HttpOnly
48
+ - _recurly_session=4755d9a612900c9652eb9bdbb4c31655; domain=.recurly.local; path=/; HttpOnly
49
49
  connection:
50
50
  - close
51
51
  server:
@@ -53,8 +53,8 @@
53
53
  body: |
54
54
  <?xml version="1.0" encoding="UTF-8"?>
55
55
  <account>
56
- <id>transaction-refund-1300473500</id>
57
- <account_code>transaction-refund-1300473500</account_code>
56
+ <id>transaction-refund-1301883347</id>
57
+ <account_code>transaction-refund-1301883347</account_code>
58
58
  <username></username>
59
59
  <email>verena@test.com</email>
60
60
  <first_name>Verena</first_name>
@@ -62,8 +62,8 @@
62
62
  <company_name>Recurly Ruby Gem</company_name>
63
63
  <balance_in_cents type="integer">0</balance_in_cents>
64
64
  <closed type="boolean">false</closed>
65
- <hosted_login_token>3bfa6969469c4f8aae86f1fa92eacd34</hosted_login_token>
66
- <created_at type="datetime">2011-03-18T18:58:36Z</created_at>
65
+ <hosted_login_token>87b28a782d6b463582ed5192d88b0645</hosted_login_token>
66
+ <created_at type="datetime">2011-04-04T02:27:17Z</created_at>
67
67
  <state>active</state>
68
68
  </account>
69
69
 
@@ -71,7 +71,7 @@
71
71
  - !ruby/struct:VCR::HTTPInteraction
72
72
  request: !ruby/struct:VCR::Request
73
73
  method: :put
74
- uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/transaction-refund-1300473500/billing_info.xml
74
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/accounts/transaction-refund-1301883347/billing_info.xml
75
75
  body: |
76
76
  <?xml version="1.0" encoding="UTF-8"?>
77
77
  <billing-info>
@@ -85,15 +85,15 @@
85
85
  <credit-card>
86
86
  <number>4111111111111111</number>
87
87
  <year type="integer">2012</year>
88
- <month type="integer">3</month>
88
+ <month type="integer">4</month>
89
89
  <verification-value>123</verification-value>
90
90
  </credit-card>
91
- <account-code>transaction-refund-1300473500</account-code>
91
+ <account-code>transaction-refund-1301883347</account-code>
92
92
  </billing-info>
93
93
 
94
94
  headers:
95
95
  authorization:
96
- - Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
96
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
97
97
  content-type:
98
98
  - application/xml
99
99
  accept:
@@ -108,17 +108,17 @@
108
108
  message: OK
109
109
  headers:
110
110
  x-runtime:
111
- - "6718"
111
+ - "1714"
112
112
  content-type:
113
113
  - application/xml; charset=utf-8
114
114
  etag:
115
- - "\"5579b8c048b119da7cfbaa074054eaec\""
115
+ - "\"d7a95f3e1f8149118b2fcfa048da0d7a\""
116
116
  cache-control:
117
117
  - private, max-age=0, must-revalidate
118
118
  content-length:
119
119
  - "644"
120
120
  set-cookie:
121
- - _recurly_session=792df3dff4f91f0fbb2ef1554482cf49; domain=.recurly.local; path=/; HttpOnly
121
+ - _recurly_session=f8426c829ad57a47fc83f86daaa44619; domain=.recurly.local; path=/; HttpOnly
122
122
  connection:
123
123
  - close
124
124
  server:
@@ -126,7 +126,7 @@
126
126
  body: |
127
127
  <?xml version="1.0" encoding="UTF-8"?>
128
128
  <billing_info>
129
- <account_code>transaction-refund-1300473500</account_code>
129
+ <account_code>transaction-refund-1301883347</account_code>
130
130
  <first_name>Verena</first_name>
131
131
  <last_name>Test</last_name>
132
132
  <address1>123 Test St</address1>
@@ -141,22 +141,22 @@
141
141
  <credit_card>
142
142
  <type>visa</type>
143
143
  <last_four>1111</last_four>
144
- <month type="integer">3</month>
144
+ <month type="integer">4</month>
145
145
  <year type="integer">2012</year>
146
146
  </credit_card>
147
- <updated_at type="datetime">2011-03-18T18:58:45Z</updated_at>
147
+ <updated_at type="datetime">2011-04-04T02:27:21Z</updated_at>
148
148
  </billing_info>
149
149
 
150
150
  http_version: "1.1"
151
151
  - !ruby/struct:VCR::HTTPInteraction
152
152
  request: !ruby/struct:VCR::Request
153
153
  method: :post
154
- uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/transactions.xml
154
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/transactions.xml
155
155
  body: |
156
156
  <?xml version="1.0" encoding="UTF-8"?>
157
157
  <transaction>
158
158
  <account>
159
- <account-code>transaction-refund-1300473500</account-code>
159
+ <account-code>transaction-refund-1301883347</account-code>
160
160
  <billing-info>
161
161
  <credit-card>
162
162
  </credit-card>
@@ -168,7 +168,7 @@
168
168
 
169
169
  headers:
170
170
  authorization:
171
- - Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
171
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
172
172
  content-type:
173
173
  - application/xml
174
174
  accept:
@@ -185,15 +185,15 @@
185
185
  cache-control:
186
186
  - no-cache
187
187
  location:
188
- - http://app.recurly.local:3000/transactions/d67b300ca27e435da25fb4be1acb5b88
188
+ - http://app.recurly.local:3000/transactions/37ae7195ccbf4182a18acc4c01155639
189
189
  x-runtime:
190
- - "6714"
190
+ - "2262"
191
191
  content-type:
192
192
  - application/xml; charset=utf-8
193
193
  content-length:
194
- - "795"
194
+ - "860"
195
195
  set-cookie:
196
- - _recurly_session=531d31550f5f3d4c638ed88a57bb6793; domain=.recurly.local; path=/; HttpOnly
196
+ - _recurly_session=b4e16fb2e3d6ddc5d8b96f0de63f897c; domain=.recurly.local; path=/; HttpOnly
197
197
  connection:
198
198
  - close
199
199
  server:
@@ -201,19 +201,19 @@
201
201
  body: |
202
202
  <?xml version="1.0" encoding="UTF-8"?>
203
203
  <transaction type="Payment">
204
- <id>d67b300ca27e435da25fb4be1acb5b88</id>
205
- <account_code>transaction-refund-1300473500</account_code>
204
+ <id>37ae7195ccbf4182a18acc4c01155639</id>
205
+ <account_code>transaction-refund-1301883347</account_code>
206
206
  <action>purchase</action>
207
- <date type="datetime">2011-03-18T18:58:52Z</date>
207
+ <date type="datetime">2011-04-04T02:27:24Z</date>
208
208
  <amount_in_cents type="integer">1000</amount_in_cents>
209
209
  <status>success</status>
210
- <message>Approved</message>
211
- <reference>819793155777085776</reference>
212
- <cvv_result code=""></cvv_result>
213
- <avs_result code=""></avs_result>
214
- <avs_result_street></avs_result_street>
215
- <avs_result_postal></avs_result_postal>
216
- <test type="boolean">false</test>
210
+ <message>Test Gateway: Successful test transaction</message>
211
+ <reference>12345</reference>
212
+ <cvv_result code="M">Match</cvv_result>
213
+ <avs_result code="D">Street address and postal code match.</avs_result>
214
+ <avs_result_street>Y</avs_result_street>
215
+ <avs_result_postal>Y</avs_result_postal>
216
+ <test type="boolean">true</test>
217
217
  <voidable type="boolean">true</voidable>
218
218
  <refundable type="boolean">true</refundable>
219
219
  <credit_card>
@@ -226,11 +226,11 @@
226
226
  - !ruby/struct:VCR::HTTPInteraction
227
227
  request: !ruby/struct:VCR::Request
228
228
  method: :delete
229
- uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/transactions/d67b300ca27e435da25fb4be1acb5b88.xml?action=refund&amount=1000
229
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/transactions/37ae7195ccbf4182a18acc4c01155639.xml?action=refund&amount=1000
230
230
  body:
231
231
  headers:
232
232
  authorization:
233
- - Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
233
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
234
234
  accept:
235
235
  - application/xml
236
236
  user-agent:
@@ -243,17 +243,17 @@
243
243
  message: OK
244
244
  headers:
245
245
  x-runtime:
246
- - "3168"
246
+ - "595"
247
247
  content-type:
248
248
  - application/xml; charset=utf-8
249
249
  etag:
250
- - "\"75512dfdfc42ddd4b69878ebd2beee4e\""
250
+ - "\"20eef6dec2b51ce98563ae99c9eb8fbb\""
251
251
  cache-control:
252
252
  - private, max-age=0, must-revalidate
253
253
  content-length:
254
- - "794"
254
+ - "859"
255
255
  set-cookie:
256
- - _recurly_session=d44edc5e8f1238f7540569c8b6981f8d; domain=.recurly.local; path=/; HttpOnly
256
+ - _recurly_session=bd8baebc1f17949db1a0e72e4f93af00; domain=.recurly.local; path=/; HttpOnly
257
257
  connection:
258
258
  - close
259
259
  server:
@@ -261,19 +261,19 @@
261
261
  body: |
262
262
  <?xml version="1.0" encoding="UTF-8"?>
263
263
  <transaction type="Payment">
264
- <id>d67b300ca27e435da25fb4be1acb5b88</id>
265
- <account_code>transaction-refund-1300473500</account_code>
264
+ <id>37ae7195ccbf4182a18acc4c01155639</id>
265
+ <account_code>transaction-refund-1301883347</account_code>
266
266
  <action>purchase</action>
267
- <date type="datetime">2011-03-18T18:58:52Z</date>
267
+ <date type="datetime">2011-04-04T02:27:24Z</date>
268
268
  <amount_in_cents type="integer">1000</amount_in_cents>
269
269
  <status>void</status>
270
- <message>Approved</message>
271
- <reference>819793155777085776</reference>
272
- <cvv_result code=""></cvv_result>
273
- <avs_result code=""></avs_result>
274
- <avs_result_street></avs_result_street>
275
- <avs_result_postal></avs_result_postal>
276
- <test type="boolean">false</test>
270
+ <message>Test Gateway: Successful test transaction</message>
271
+ <reference>12345</reference>
272
+ <cvv_result code="M">Match</cvv_result>
273
+ <avs_result code="D">Street address and postal code match.</avs_result>
274
+ <avs_result_street>Y</avs_result_street>
275
+ <avs_result_postal>Y</avs_result_postal>
276
+ <test type="boolean">true</test>
277
277
  <voidable type="boolean">false</voidable>
278
278
  <refundable type="boolean">false</refundable>
279
279
  <credit_card>
@@ -0,0 +1,365 @@
1
+ ---
2
+ - !ruby/struct:VCR::HTTPInteraction
3
+ request: !ruby/struct:VCR::Request
4
+ method: :post
5
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/accounts.xml
6
+ body: |
7
+ <?xml version="1.0" encoding="UTF-8"?>
8
+ <account>
9
+ <account-code>transaction-void-1301883347</account-code>
10
+ <first-name>Verena</first-name>
11
+ <last-name>Test</last-name>
12
+ <email>verena@test.com</email>
13
+ <company-name>Recurly Ruby Gem</company-name>
14
+ <billing-info>
15
+ <credit-card>
16
+ </credit-card>
17
+ </billing-info>
18
+ <accept-language type="yaml" nil="true"></accept-language>
19
+ </account>
20
+
21
+ headers:
22
+ authorization:
23
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
24
+ content-type:
25
+ - application/xml
26
+ accept:
27
+ - "*/*"
28
+ user-agent:
29
+ - Ruby
30
+ connection:
31
+ - close
32
+ response: !ruby/struct:VCR::Response
33
+ status: !ruby/struct:VCR::ResponseStatus
34
+ code: 201
35
+ message: Created
36
+ headers:
37
+ cache-control:
38
+ - no-cache
39
+ location:
40
+ - http://app.recurly.local:3000/accounts/transaction-void-1301883347
41
+ x-runtime:
42
+ - "313"
43
+ content-type:
44
+ - application/xml; charset=utf-8
45
+ content-length:
46
+ - "587"
47
+ set-cookie:
48
+ - _recurly_session=b3d1a99e11b7d920babf589290a4b675; domain=.recurly.local; path=/; HttpOnly
49
+ connection:
50
+ - close
51
+ server:
52
+ - thin 1.2.7 codename No Hup
53
+ body: |
54
+ <?xml version="1.0" encoding="UTF-8"?>
55
+ <account>
56
+ <id>transaction-void-1301883347</id>
57
+ <account_code>transaction-void-1301883347</account_code>
58
+ <username></username>
59
+ <email>verena@test.com</email>
60
+ <first_name>Verena</first_name>
61
+ <last_name>Test</last_name>
62
+ <company_name>Recurly Ruby Gem</company_name>
63
+ <balance_in_cents type="integer">0</balance_in_cents>
64
+ <closed type="boolean">false</closed>
65
+ <hosted_login_token>d3d5efec55dd4a68a19b0b1493863cc1</hosted_login_token>
66
+ <created_at type="datetime">2011-04-04T02:27:03Z</created_at>
67
+ <state>active</state>
68
+ </account>
69
+
70
+ http_version: "1.1"
71
+ - !ruby/struct:VCR::HTTPInteraction
72
+ request: !ruby/struct:VCR::Request
73
+ method: :put
74
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/accounts/transaction-void-1301883347/billing_info.xml
75
+ body: |
76
+ <?xml version="1.0" encoding="UTF-8"?>
77
+ <billing-info>
78
+ <first-name>Verena</first-name>
79
+ <last-name>Test</last-name>
80
+ <address1>123 Test St</address1>
81
+ <city>San Francisco</city>
82
+ <state>CA</state>
83
+ <zip>94115</zip>
84
+ <country>US</country>
85
+ <credit-card>
86
+ <number>4111111111111111</number>
87
+ <year type="integer">2012</year>
88
+ <month type="integer">4</month>
89
+ <verification-value>123</verification-value>
90
+ </credit-card>
91
+ <account-code>transaction-void-1301883347</account-code>
92
+ </billing-info>
93
+
94
+ headers:
95
+ authorization:
96
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
97
+ content-type:
98
+ - application/xml
99
+ accept:
100
+ - "*/*"
101
+ user-agent:
102
+ - Ruby
103
+ connection:
104
+ - close
105
+ response: !ruby/struct:VCR::Response
106
+ status: !ruby/struct:VCR::ResponseStatus
107
+ code: 200
108
+ message: OK
109
+ headers:
110
+ x-runtime:
111
+ - "1784"
112
+ content-type:
113
+ - application/xml; charset=utf-8
114
+ etag:
115
+ - "\"0ba7299345a594479d9c9220689c97ef\""
116
+ cache-control:
117
+ - private, max-age=0, must-revalidate
118
+ content-length:
119
+ - "642"
120
+ set-cookie:
121
+ - _recurly_session=a1c38a71a9741db3aac533e706801120; domain=.recurly.local; path=/; HttpOnly
122
+ connection:
123
+ - close
124
+ server:
125
+ - thin 1.2.7 codename No Hup
126
+ body: |
127
+ <?xml version="1.0" encoding="UTF-8"?>
128
+ <billing_info>
129
+ <account_code>transaction-void-1301883347</account_code>
130
+ <first_name>Verena</first_name>
131
+ <last_name>Test</last_name>
132
+ <address1>123 Test St</address1>
133
+ <address2></address2>
134
+ <city>San Francisco</city>
135
+ <state>CA</state>
136
+ <country>US</country>
137
+ <zip>94115</zip>
138
+ <phone></phone>
139
+ <vat_number></vat_number>
140
+ <ip_address></ip_address>
141
+ <credit_card>
142
+ <type>visa</type>
143
+ <last_four>1111</last_four>
144
+ <month type="integer">4</month>
145
+ <year type="integer">2012</year>
146
+ </credit_card>
147
+ <updated_at type="datetime">2011-04-04T02:27:07Z</updated_at>
148
+ </billing_info>
149
+
150
+ http_version: "1.1"
151
+ - !ruby/struct:VCR::HTTPInteraction
152
+ request: !ruby/struct:VCR::Request
153
+ method: :post
154
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/transactions.xml
155
+ body: |
156
+ <?xml version="1.0" encoding="UTF-8"?>
157
+ <transaction>
158
+ <account>
159
+ <account-code>transaction-void-1301883347</account-code>
160
+ <billing-info>
161
+ <credit-card>
162
+ </credit-card>
163
+ </billing-info>
164
+ </account>
165
+ <amount-in-cents type="integer">100</amount-in-cents>
166
+ <description>one</description>
167
+ </transaction>
168
+
169
+ headers:
170
+ authorization:
171
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
172
+ content-type:
173
+ - application/xml
174
+ accept:
175
+ - "*/*"
176
+ user-agent:
177
+ - Ruby
178
+ connection:
179
+ - close
180
+ response: !ruby/struct:VCR::Response
181
+ status: !ruby/struct:VCR::ResponseStatus
182
+ code: 201
183
+ message: Created
184
+ headers:
185
+ cache-control:
186
+ - no-cache
187
+ location:
188
+ - http://app.recurly.local:3000/transactions/b0edb36553f24330895f1fb78dda4af8
189
+ x-runtime:
190
+ - "2031"
191
+ content-type:
192
+ - application/xml; charset=utf-8
193
+ content-length:
194
+ - "857"
195
+ set-cookie:
196
+ - _recurly_session=a8f6bf410feacda4460a44bfe2409905; domain=.recurly.local; path=/; HttpOnly
197
+ connection:
198
+ - close
199
+ server:
200
+ - thin 1.2.7 codename No Hup
201
+ body: |
202
+ <?xml version="1.0" encoding="UTF-8"?>
203
+ <transaction type="Payment">
204
+ <id>b0edb36553f24330895f1fb78dda4af8</id>
205
+ <account_code>transaction-void-1301883347</account_code>
206
+ <action>purchase</action>
207
+ <date type="datetime">2011-04-04T02:27:10Z</date>
208
+ <amount_in_cents type="integer">100</amount_in_cents>
209
+ <status>success</status>
210
+ <message>Test Gateway: Successful test transaction</message>
211
+ <reference>12345</reference>
212
+ <cvv_result code="M">Match</cvv_result>
213
+ <avs_result code="D">Street address and postal code match.</avs_result>
214
+ <avs_result_street>Y</avs_result_street>
215
+ <avs_result_postal>Y</avs_result_postal>
216
+ <test type="boolean">true</test>
217
+ <voidable type="boolean">true</voidable>
218
+ <refundable type="boolean">true</refundable>
219
+ <credit_card>
220
+ <type>visa</type>
221
+ <last_four>1111</last_four>
222
+ </credit_card>
223
+ </transaction>
224
+
225
+ http_version: "1.1"
226
+ - !ruby/struct:VCR::HTTPInteraction
227
+ request: !ruby/struct:VCR::Request
228
+ method: :delete
229
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/transactions/b0edb36553f24330895f1fb78dda4af8.xml?action=void
230
+ body:
231
+ headers:
232
+ authorization:
233
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
234
+ accept:
235
+ - application/xml
236
+ user-agent:
237
+ - Ruby
238
+ connection:
239
+ - close
240
+ response: !ruby/struct:VCR::Response
241
+ status: !ruby/struct:VCR::ResponseStatus
242
+ code: 200
243
+ message: OK
244
+ headers:
245
+ x-runtime:
246
+ - "599"
247
+ content-type:
248
+ - application/xml; charset=utf-8
249
+ etag:
250
+ - "\"fcd5b4cd7e4b6272218ed8d27a3f9355\""
251
+ cache-control:
252
+ - private, max-age=0, must-revalidate
253
+ content-length:
254
+ - "856"
255
+ set-cookie:
256
+ - _recurly_session=b0f8beae9debddd226acc574ccec8546; domain=.recurly.local; path=/; HttpOnly
257
+ connection:
258
+ - close
259
+ server:
260
+ - thin 1.2.7 codename No Hup
261
+ body: |
262
+ <?xml version="1.0" encoding="UTF-8"?>
263
+ <transaction type="Payment">
264
+ <id>b0edb36553f24330895f1fb78dda4af8</id>
265
+ <account_code>transaction-void-1301883347</account_code>
266
+ <action>purchase</action>
267
+ <date type="datetime">2011-04-04T02:27:10Z</date>
268
+ <amount_in_cents type="integer">100</amount_in_cents>
269
+ <status>void</status>
270
+ <message>Test Gateway: Successful test transaction</message>
271
+ <reference>12345</reference>
272
+ <cvv_result code="M">Match</cvv_result>
273
+ <avs_result code="D">Street address and postal code match.</avs_result>
274
+ <avs_result_street>Y</avs_result_street>
275
+ <avs_result_postal>Y</avs_result_postal>
276
+ <test type="boolean">true</test>
277
+ <voidable type="boolean">false</voidable>
278
+ <refundable type="boolean">false</refundable>
279
+ <credit_card>
280
+ <type>visa</type>
281
+ <last_four>1111</last_four>
282
+ </credit_card>
283
+ </transaction>
284
+
285
+ http_version: "1.1"
286
+ - !ruby/struct:VCR::HTTPInteraction
287
+ request: !ruby/struct:VCR::Request
288
+ method: :get
289
+ uri: http://api-test%40hello-test.com:50a5b8a69a2545db84ac4112ba8cac6f@app.recurly.local:3000/transactions.xml?show=voided
290
+ body:
291
+ headers:
292
+ authorization:
293
+ - Basic YXBpLXRlc3RAaGVsbG8tdGVzdC5jb206NTBhNWI4YTY5YTI1NDVkYjg0YWM0MTEyYmE4Y2FjNmY=
294
+ accept:
295
+ - application/xml
296
+ accept-encoding:
297
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
298
+ user-agent:
299
+ - Ruby
300
+ connection:
301
+ - close
302
+ response: !ruby/struct:VCR::Response
303
+ status: !ruby/struct:VCR::ResponseStatus
304
+ code: 200
305
+ message: OK
306
+ headers:
307
+ x-runtime:
308
+ - "311"
309
+ content-type:
310
+ - application/xml; charset=utf-8
311
+ etag:
312
+ - "\"57787eba5407e32cf95af00fd32ab762\""
313
+ cache-control:
314
+ - private, max-age=0, must-revalidate
315
+ content-length:
316
+ - "1763"
317
+ set-cookie:
318
+ - _recurly_session=4793e6b93dcbacfd67c1f81c5f385c35; domain=.recurly.local; path=/; HttpOnly
319
+ connection:
320
+ - close
321
+ server:
322
+ - thin 1.2.7 codename No Hup
323
+ body: |
324
+ <?xml version="1.0" encoding="UTF-8"?>
325
+ <transactions type="collection">
326
+ <current_page type="integer">1</current_page>
327
+ <per_page type="integer">20</per_page>
328
+ <total_entries type="integer">2</total_entries>
329
+ <transaction type="Payment">
330
+ <id>b0edb36553f24330895f1fb78dda4af8</id>
331
+ <account_code>transaction-void-1301883347</account_code>
332
+ <action>purchase</action>
333
+ <date type="datetime">2011-04-04T02:27:10Z</date>
334
+ <amount_in_cents type="integer">100</amount_in_cents>
335
+ <status>void</status>
336
+ <message>Test Gateway: Successful test transaction</message>
337
+ <reference>12345</reference>
338
+ <cvv_result code="M">Match</cvv_result>
339
+ <avs_result code="D">Street address and postal code match.</avs_result>
340
+ <avs_result_street>Y</avs_result_street>
341
+ <avs_result_postal>Y</avs_result_postal>
342
+ <test type="boolean">true</test>
343
+ <voidable type="boolean">false</voidable>
344
+ <refundable type="boolean">false</refundable>
345
+ </transaction>
346
+ <transaction type="Payment">
347
+ <id>76b53b7d65264c8b99d18757235d4940</id>
348
+ <account_code>subscription-refund-full-1301881900</account_code>
349
+ <action>purchase</action>
350
+ <date type="datetime">2011-04-04T02:25:05Z</date>
351
+ <amount_in_cents type="integer">200</amount_in_cents>
352
+ <status>void</status>
353
+ <message>Test Gateway: Successful test transaction</message>
354
+ <reference>12345</reference>
355
+ <cvv_result code="M">Match</cvv_result>
356
+ <avs_result code="D">Street address and postal code match.</avs_result>
357
+ <avs_result_street>Y</avs_result_street>
358
+ <avs_result_postal>Y</avs_result_postal>
359
+ <test type="boolean">true</test>
360
+ <voidable type="boolean">false</voidable>
361
+ <refundable type="boolean">false</refundable>
362
+ </transaction>
363
+ </transactions>
364
+
365
+ http_version: "1.1"