recurly 0.4.11 → 0.4.13

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 (70) hide show
  1. data/README.md +4 -8
  2. data/lib/recurly.rb +10 -19
  3. data/lib/recurly/config_parser.rb +5 -2
  4. data/lib/recurly/plan.rb +0 -1
  5. data/lib/recurly/rails3/recurly.rake +10 -26
  6. data/lib/recurly/transparent.rb +2 -0
  7. data/lib/recurly/verification.rb +14 -8
  8. data/lib/recurly/version.rb +1 -1
  9. data/spec/config/recurly.yml +3 -3
  10. data/spec/config/test1.yml +1 -3
  11. data/spec/config/test2.yml +2 -6
  12. data/spec/unit/config_spec.rb +9 -16
  13. data/spec/unit/transparent_spec.rb +0 -20
  14. data/spec/unit/verification_spec.rb +15 -9
  15. data/spec/vcr/account/accept-language-account/1313708721.yml +52 -31
  16. data/spec/vcr/account/close/1313708721.yml +107 -79
  17. data/spec/vcr/account/create-blank/1313708721.yml +37 -26
  18. data/spec/vcr/account/create-duplicate/1313708721.yml +83 -54
  19. data/spec/vcr/account/create-min/1313708721.yml +48 -30
  20. data/spec/vcr/account/create/1313708721.yml +52 -31
  21. data/spec/vcr/account/find/1313708721.yml +111 -81
  22. data/spec/vcr/account/list/1313708721.yml +1148 -719
  23. data/spec/vcr/account/update/1313708721.yml +182 -124
  24. data/spec/vcr/billing/create/1313708721.yml +156 -93
  25. data/spec/vcr/billing/destroy/1313708721.yml +198 -135
  26. data/spec/vcr/billing/errors/1313708721.yml +91 -56
  27. data/spec/vcr/billing/find/1313708721.yml +200 -122
  28. data/spec/vcr/billing/update/1313708721.yml +218 -126
  29. data/spec/vcr/charge/create/1313708721.yml +189 -120
  30. data/spec/vcr/charge/delete-uninvoiced/1313708721.yml +195 -154
  31. data/spec/vcr/charge/list-all/1313708721.yml +235 -157
  32. data/spec/vcr/charge/list-invoiced/1313708721.yml +351 -234
  33. data/spec/vcr/charge/list-pending/1313708721.yml +235 -159
  34. data/spec/vcr/charge/lookup/1313708721.yml +127 -87
  35. data/spec/vcr/coupon/create/1296774903.yml +83 -95
  36. data/spec/vcr/coupon/destroy/1296774903.yml +81 -115
  37. data/spec/vcr/credit/create/1313708090.yml +127 -87
  38. data/spec/vcr/credit/delete/1313708090.yml +169 -129
  39. data/spec/vcr/credit/list/1313708090.yml +235 -157
  40. data/spec/vcr/credit/lookup/1313708090.yml +127 -87
  41. data/spec/vcr/invoice/create-no-charges/1296674173.yml +140 -89
  42. data/spec/vcr/invoice/create/1296674173.yml +259 -162
  43. data/spec/vcr/invoice/list/1296674173.yml +342 -227
  44. data/spec/vcr/invoice/lookup/1296674173.yml +260 -167
  45. data/spec/vcr/plan/all.yml +206 -198
  46. data/spec/vcr/plan/find.yml +109 -103
  47. data/spec/vcr/plan/update.yml +126 -93
  48. data/spec/vcr/subscription/addons/add/1296674173.yml +156 -261
  49. data/spec/vcr/subscription/addons/create/1296674173.yml +156 -164
  50. data/spec/vcr/subscription/addons/remove/1296674173.yml +156 -249
  51. data/spec/vcr/subscription/cancel-with-code/1296674173.yml +340 -243
  52. data/spec/vcr/subscription/cancel/1296674173.yml +297 -210
  53. data/spec/vcr/subscription/change1/1296674173.yml +303 -213
  54. data/spec/vcr/subscription/change2/1296674173.yml +303 -214
  55. data/spec/vcr/subscription/create/1296674173.yml +167 -111
  56. data/spec/vcr/subscription/find/1296674173.yml +210 -145
  57. data/spec/vcr/subscription/reactivate/1296674173.yml +318 -233
  58. data/spec/vcr/subscription/refund-full/1296674173.yml +277 -199
  59. data/spec/vcr/subscription/refund-none/1296674173.yml +277 -199
  60. data/spec/vcr/subscription/refund-partial/1296674173.yml +277 -199
  61. data/spec/vcr/transaction/all/1311126815.yml +388 -206
  62. data/spec/vcr/transaction/create-no-account/1311126815.yml +74 -43
  63. data/spec/vcr/transaction/create-with-account/1311126815.yml +172 -101
  64. data/spec/vcr/transaction/list-filled/1311126815.yml +486 -291
  65. data/spec/vcr/transaction/list-initial/1311126815.yml +159 -98
  66. data/spec/vcr/transaction/lookup/1311126815.yml +420 -268
  67. data/spec/vcr/transaction/void/1311126815.yml +280 -174
  68. metadata +109 -77
  69. data/spec/vcr/transaction/refund/1311126815.yml +0 -163
  70. data/spec/vcr/transparent/post-url/1311239470.yml +0 -76
@@ -1,171 +1,211 @@
1
- ---
2
- - !ruby/struct:VCR::HTTPInteraction
3
- request: !ruby/struct:VCR::Request
1
+ ---
2
+ - !ruby/struct:VCR::HTTPInteraction
3
+ request: !ruby/struct:VCR::Request
4
4
  method: :post
5
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts.xml
6
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<account>\n <account-code>delete-uninvoiced-1313708090</account-code>\n
7
- \ <first-name>Verena</first-name>\n <last-name>Test</last-name>\n <email>verena@test.com</email>\n
8
- \ <company-name>Recurly Ruby Gem</company-name>\n <billing-info>\n <credit-card>\n
9
- \ </credit-card>\n </billing-info>\n <accept-language nil=\"true\"></accept-language>\n</account>\n"
10
- headers:
11
- user-agent:
12
- - Recurly Ruby Client v0.4.10
13
- content-type:
5
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts.xml
6
+ body: |
7
+ <?xml version="1.0" encoding="UTF-8"?>
8
+ <account>
9
+ <account-code>delete-uninvoiced-1313708090</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 nil="true"></accept-language>
19
+ </account>
20
+
21
+ headers:
22
+ user-agent:
23
+ - Recurly Ruby Client v0.4.13
24
+ content-type:
14
25
  - application/xml
15
- response: !ruby/struct:VCR::Response
16
- status: !ruby/struct:VCR::ResponseStatus
26
+ response: !ruby/struct:VCR::Response
27
+ status: !ruby/struct:VCR::ResponseStatus
17
28
  code: 201
18
29
  message: Created
19
- headers:
20
- location:
21
- - http://app.lvh.me:3000/accounts/delete-uninvoiced-1313708090
22
- content-type:
30
+ headers:
31
+ location:
32
+ - http://api.lvh.me:3000/accounts/delete-uninvoiced-1313708090
33
+ content-type:
23
34
  - application/xml; charset=utf-8
24
- cache-control:
35
+ cache-control:
25
36
  - no-cache
26
- x-ua-compatible:
37
+ x-ua-compatible:
27
38
  - IE=Edge
28
- set-cookie:
29
- - _recurly_session=1149cc4bf1bf8263f896f14e33b4d79f; domain=.lvh.me; path=/;
30
- HttpOnly
31
- server:
39
+ set-cookie:
40
+ - _recurly_session=62116a575ee5ade0541c5adc6d4cb36d; domain=.lvh.me; path=/; HttpOnly
41
+ server:
32
42
  - thin 1.2.11 codename Bat-Shit Crazy
33
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<account>\n <id>delete-uninvoiced-1313708090</id>\n
34
- \ <account_code>delete-uninvoiced-1313708090</account_code>\n <username></username>\n
35
- \ <email>verena@test.com</email>\n <first_name>Verena</first_name>\n <last_name>Test</last_name>\n
36
- \ <company_name>Recurly Ruby Gem</company_name>\n <balance_in_cents type=\"integer\">0</balance_in_cents>\n
37
- \ <closed type=\"boolean\">false</closed>\n <hosted_login_token>7b7da9f2792f4f448e60b5f4074cfda9</hosted_login_token>\n
38
- \ <created_at type=\"datetime\">2011-08-19T20:01:46Z</created_at>\n <state>active</state>\n</account>\n"
39
- http_version: '1.1'
40
- - !ruby/struct:VCR::HTTPInteraction
41
- request: !ruby/struct:VCR::Request
43
+ body: |
44
+ <?xml version="1.0" encoding="UTF-8"?>
45
+ <account>
46
+ <id>delete-uninvoiced-1313708090</id>
47
+ <account_code>delete-uninvoiced-1313708090</account_code>
48
+ <username></username>
49
+ <email>verena@test.com</email>
50
+ <first_name>Verena</first_name>
51
+ <last_name>Test</last_name>
52
+ <company_name>Recurly Ruby Gem</company_name>
53
+ <balance_in_cents type="integer">0</balance_in_cents>
54
+ <closed type="boolean">false</closed>
55
+ <hosted_login_token>3ded94c7223144b783a509bb2f769786</hosted_login_token>
56
+ <created_at type="datetime">2011-09-22T22:01:48Z</created_at>
57
+ <state>active</state>
58
+ </account>
59
+
60
+ http_version: "1.1"
61
+ - !ruby/struct:VCR::HTTPInteraction
62
+ request: !ruby/struct:VCR::Request
42
63
  method: :post
43
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits.xml
44
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit>\n <amount-in-cents
45
- type=\"integer\">1315</amount-in-cents>\n <description>free moniez 4 u</description>\n</credit>\n"
46
- headers:
47
- user-agent:
48
- - Recurly Ruby Client v0.4.10
49
- content-type:
64
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits.xml
65
+ body: |
66
+ <?xml version="1.0" encoding="UTF-8"?>
67
+ <credit>
68
+ <amount-in-cents type="integer">1315</amount-in-cents>
69
+ <description>free moniez 4 u</description>
70
+ </credit>
71
+
72
+ headers:
73
+ user-agent:
74
+ - Recurly Ruby Client v0.4.13
75
+ content-type:
50
76
  - application/xml
51
- response: !ruby/struct:VCR::Response
52
- status: !ruby/struct:VCR::ResponseStatus
77
+ response: !ruby/struct:VCR::Response
78
+ status: !ruby/struct:VCR::ResponseStatus
53
79
  code: 201
54
80
  message: Created
55
- headers:
56
- content-type:
81
+ headers:
82
+ content-type:
57
83
  - application/xml; charset=utf-8
58
- cache-control:
84
+ cache-control:
59
85
  - no-cache
60
- x-ua-compatible:
86
+ x-ua-compatible:
61
87
  - IE=Edge
62
- set-cookie:
63
- - _recurly_session=d8d682a6cf3f3389aa4f5a80b7c2f609; domain=.lvh.me; path=/;
64
- HttpOnly
65
- server:
88
+ set-cookie:
89
+ - _recurly_session=0cbf283741badc2e3cfa3977e387704d; domain=.lvh.me; path=/; HttpOnly
90
+ server:
66
91
  - thin 1.2.11 codename Bat-Shit Crazy
67
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit type=\"credit\">\n
68
- \ <id>da67485dd91a4ccc833341eb627ffca1</id>\n <account_code>delete-uninvoiced-1313708090</account_code>\n
69
- \ <quantity type=\"integer\">1</quantity>\n <unit_amount_in_cents type=\"integer\">-1315</unit_amount_in_cents>\n
70
- \ <amount_in_cents type=\"integer\">-1315</amount_in_cents>\n <currency>USD</currency>\n
71
- \ <start_date type=\"datetime\">2011-08-19T20:01:46Z</start_date>\n <end_date
72
- nil=\"true\" type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
73
- \ <description>free moniez 4 u</description>\n <created_at type=\"datetime\">2011-08-19T20:01:46Z</created_at>\n</credit>\n"
74
- http_version: '1.1'
75
- - !ruby/struct:VCR::HTTPInteraction
76
- request: !ruby/struct:VCR::Request
92
+ body: |
93
+ <?xml version="1.0" encoding="UTF-8"?>
94
+ <credit type="credit">
95
+ <id>f4be3e9011a044369ac5de391c6fd8fb</id>
96
+ <account_code>delete-uninvoiced-1313708090</account_code>
97
+ <quantity type="integer">1</quantity>
98
+ <unit_amount_in_cents type="integer">-1315</unit_amount_in_cents>
99
+ <amount_in_cents type="integer">-1315</amount_in_cents>
100
+ <currency>USD</currency>
101
+ <start_date type="datetime">2011-09-22T22:01:48Z</start_date>
102
+ <end_date nil="true" type="datetime"></end_date>
103
+ <invoice_number nil="true" type="integer"></invoice_number>
104
+ <description>free moniez 4 u</description>
105
+ <created_at type="datetime">2011-09-22T22:01:48Z</created_at>
106
+ </credit>
107
+
108
+ http_version: "1.1"
109
+ - !ruby/struct:VCR::HTTPInteraction
110
+ request: !ruby/struct:VCR::Request
77
111
  method: :get
78
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits/da67485dd91a4ccc833341eb627ffca1.xml
79
- body: !!null
80
- headers:
81
- user-agent:
82
- - Recurly Ruby Client v0.4.10
83
- accept:
112
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits/f4be3e9011a044369ac5de391c6fd8fb.xml
113
+ body:
114
+ headers:
115
+ user-agent:
116
+ - Recurly Ruby Client v0.4.13
117
+ accept:
84
118
  - application/xml
85
- accept-encoding:
119
+ accept-encoding:
86
120
  - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
87
- response: !ruby/struct:VCR::Response
88
- status: !ruby/struct:VCR::ResponseStatus
121
+ response: !ruby/struct:VCR::Response
122
+ status: !ruby/struct:VCR::ResponseStatus
89
123
  code: 200
90
124
  message: OK
91
- headers:
92
- content-type:
125
+ headers:
126
+ content-type:
93
127
  - application/xml; charset=utf-8
94
- etag:
95
- - ! '"36fb323e4272e06eddb92843d2b8230e"'
96
- cache-control:
128
+ etag:
129
+ - "\"626d5556ddef0bf781d7ee5aee7b5111\""
130
+ cache-control:
97
131
  - max-age=0, private, must-revalidate
98
- x-ua-compatible:
132
+ x-ua-compatible:
99
133
  - IE=Edge
100
- set-cookie:
101
- - _recurly_session=4dc6a0b9e3535c0554c9b432973de7e1; domain=.lvh.me; path=/;
102
- HttpOnly
103
- server:
134
+ server:
104
135
  - thin 1.2.11 codename Bat-Shit Crazy
105
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit type=\"credit\">\n
106
- \ <id>da67485dd91a4ccc833341eb627ffca1</id>\n <account_code>delete-uninvoiced-1313708090</account_code>\n
107
- \ <quantity type=\"integer\">1</quantity>\n <unit_amount_in_cents type=\"integer\">-1315</unit_amount_in_cents>\n
108
- \ <amount_in_cents type=\"integer\">-1315</amount_in_cents>\n <currency>USD</currency>\n
109
- \ <start_date type=\"datetime\">2011-08-19T20:01:46Z</start_date>\n <end_date
110
- nil=\"true\" type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
111
- \ <description>free moniez 4 u</description>\n <created_at type=\"datetime\">2011-08-19T20:01:46Z</created_at>\n</credit>\n"
112
- http_version: '1.1'
113
- - !ruby/struct:VCR::HTTPInteraction
114
- request: !ruby/struct:VCR::Request
136
+ body: |
137
+ <?xml version="1.0" encoding="UTF-8"?>
138
+ <credit type="credit">
139
+ <id>f4be3e9011a044369ac5de391c6fd8fb</id>
140
+ <account_code>delete-uninvoiced-1313708090</account_code>
141
+ <quantity type="integer">1</quantity>
142
+ <unit_amount_in_cents type="integer">-1315</unit_amount_in_cents>
143
+ <amount_in_cents type="integer">-1315</amount_in_cents>
144
+ <currency>USD</currency>
145
+ <start_date type="datetime">2011-09-22T22:01:48Z</start_date>
146
+ <end_date nil="true" type="datetime"></end_date>
147
+ <invoice_number nil="true" type="integer"></invoice_number>
148
+ <description>free moniez 4 u</description>
149
+ <created_at type="datetime">2011-09-22T22:01:48Z</created_at>
150
+ </credit>
151
+
152
+ http_version: "1.1"
153
+ - !ruby/struct:VCR::HTTPInteraction
154
+ request: !ruby/struct:VCR::Request
115
155
  method: :delete
116
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits/da67485dd91a4ccc833341eb627ffca1.xml
117
- body: !!null
118
- headers:
119
- user-agent:
120
- - Recurly Ruby Client v0.4.10
121
- accept:
156
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits/f4be3e9011a044369ac5de391c6fd8fb.xml
157
+ body:
158
+ headers:
159
+ user-agent:
160
+ - Recurly Ruby Client v0.4.13
161
+ accept:
122
162
  - application/xml
123
- response: !ruby/struct:VCR::Response
124
- status: !ruby/struct:VCR::ResponseStatus
163
+ response: !ruby/struct:VCR::Response
164
+ status: !ruby/struct:VCR::ResponseStatus
125
165
  code: 200
126
166
  message: OK
127
- headers:
128
- content-type:
167
+ headers:
168
+ content-type:
129
169
  - application/xml; charset=utf-8
130
- cache-control:
170
+ cache-control:
131
171
  - no-cache
132
- x-ua-compatible:
172
+ x-ua-compatible:
133
173
  - IE=Edge
134
- set-cookie:
135
- - _recurly_session=6d216b4a75eaee6f94881c909de856a9; domain=.lvh.me; path=/;
136
- HttpOnly
137
- server:
174
+ set-cookie:
175
+ - _recurly_session=4ccc168c65219924be05a5a52e37ed1a; domain=.lvh.me; path=/; HttpOnly
176
+ server:
138
177
  - thin 1.2.11 codename Bat-Shit Crazy
139
- body: ! ' '
140
- http_version: '1.1'
141
- - !ruby/struct:VCR::HTTPInteraction
142
- request: !ruby/struct:VCR::Request
178
+ body: " "
179
+ http_version: "1.1"
180
+ - !ruby/struct:VCR::HTTPInteraction
181
+ request: !ruby/struct:VCR::Request
143
182
  method: :get
144
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits/da67485dd91a4ccc833341eb627ffca1.xml
145
- body: !!null
146
- headers:
147
- user-agent:
148
- - Recurly Ruby Client v0.4.10
149
- accept:
183
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/delete-uninvoiced-1313708090/credits/f4be3e9011a044369ac5de391c6fd8fb.xml
184
+ body:
185
+ headers:
186
+ user-agent:
187
+ - Recurly Ruby Client v0.4.13
188
+ accept:
150
189
  - application/xml
151
- accept-encoding:
190
+ accept-encoding:
152
191
  - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
153
- response: !ruby/struct:VCR::Response
154
- status: !ruby/struct:VCR::ResponseStatus
192
+ response: !ruby/struct:VCR::Response
193
+ status: !ruby/struct:VCR::ResponseStatus
155
194
  code: 404
156
195
  message: Not Found
157
- headers:
158
- content-type:
196
+ headers:
197
+ content-type:
159
198
  - application/xml; charset=utf-8
160
- cache-control:
199
+ cache-control:
161
200
  - no-cache
162
- x-ua-compatible:
201
+ x-ua-compatible:
163
202
  - IE=Edge
164
- set-cookie:
165
- - _recurly_session=f74a0dbf102db77ac9d97607024b2c81; domain=.lvh.me; path=/;
166
- HttpOnly
167
- server:
203
+ server:
168
204
  - thin 1.2.11 codename Bat-Shit Crazy
169
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<errors>\n <error>Credit
170
- not found</error>\n</errors>\n"
171
- http_version: '1.1'
205
+ body: |
206
+ <?xml version="1.0" encoding="UTF-8"?>
207
+ <errors>
208
+ <error>Credit not found</error>
209
+ </errors>
210
+
211
+ http_version: "1.1"
@@ -1,198 +1,276 @@
1
- ---
2
- - !ruby/struct:VCR::HTTPInteraction
3
- request: !ruby/struct:VCR::Request
1
+ ---
2
+ - !ruby/struct:VCR::HTTPInteraction
3
+ request: !ruby/struct:VCR::Request
4
4
  method: :post
5
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts.xml
6
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<account>\n <account-code>credit-list-1313708090</account-code>\n
7
- \ <first-name>Verena</first-name>\n <last-name>Test</last-name>\n <email>verena@test.com</email>\n
8
- \ <company-name>Recurly Ruby Gem</company-name>\n <billing-info>\n <credit-card>\n
9
- \ </credit-card>\n </billing-info>\n <accept-language nil=\"true\"></accept-language>\n</account>\n"
10
- headers:
11
- user-agent:
12
- - Recurly Ruby Client v0.4.10
13
- content-type:
5
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts.xml
6
+ body: |
7
+ <?xml version="1.0" encoding="UTF-8"?>
8
+ <account>
9
+ <account-code>credit-list-1313708090</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 nil="true"></accept-language>
19
+ </account>
20
+
21
+ headers:
22
+ user-agent:
23
+ - Recurly Ruby Client v0.4.13
24
+ content-type:
14
25
  - application/xml
15
- response: !ruby/struct:VCR::Response
16
- status: !ruby/struct:VCR::ResponseStatus
26
+ response: !ruby/struct:VCR::Response
27
+ status: !ruby/struct:VCR::ResponseStatus
17
28
  code: 201
18
29
  message: Created
19
- headers:
20
- location:
21
- - http://app.lvh.me:3000/accounts/credit-list-1313708090
22
- content-type:
30
+ headers:
31
+ location:
32
+ - http://api.lvh.me:3000/accounts/credit-list-1313708090
33
+ content-type:
23
34
  - application/xml; charset=utf-8
24
- cache-control:
35
+ cache-control:
25
36
  - no-cache
26
- x-ua-compatible:
37
+ x-ua-compatible:
27
38
  - IE=Edge
28
- set-cookie:
29
- - _recurly_session=d2a2162cd128aab7891ffadb785b912a; domain=.lvh.me; path=/;
30
- HttpOnly
31
- server:
39
+ set-cookie:
40
+ - _recurly_session=39ec21c4ebab7cfe217d6ad89d8ca398; domain=.lvh.me; path=/; HttpOnly
41
+ server:
32
42
  - thin 1.2.11 codename Bat-Shit Crazy
33
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<account>\n <id>credit-list-1313708090</id>\n
34
- \ <account_code>credit-list-1313708090</account_code>\n <username></username>\n
35
- \ <email>verena@test.com</email>\n <first_name>Verena</first_name>\n <last_name>Test</last_name>\n
36
- \ <company_name>Recurly Ruby Gem</company_name>\n <balance_in_cents type=\"integer\">0</balance_in_cents>\n
37
- \ <closed type=\"boolean\">false</closed>\n <hosted_login_token>34eeab2db1144020878c3a7d0e5fa953</hosted_login_token>\n
38
- \ <created_at type=\"datetime\">2011-08-19T20:01:44Z</created_at>\n <state>active</state>\n</account>\n"
39
- http_version: '1.1'
40
- - !ruby/struct:VCR::HTTPInteraction
41
- request: !ruby/struct:VCR::Request
43
+ body: |
44
+ <?xml version="1.0" encoding="UTF-8"?>
45
+ <account>
46
+ <id>credit-list-1313708090</id>
47
+ <account_code>credit-list-1313708090</account_code>
48
+ <username></username>
49
+ <email>verena@test.com</email>
50
+ <first_name>Verena</first_name>
51
+ <last_name>Test</last_name>
52
+ <company_name>Recurly Ruby Gem</company_name>
53
+ <balance_in_cents type="integer">0</balance_in_cents>
54
+ <closed type="boolean">false</closed>
55
+ <hosted_login_token>1f1ad94e986e40c7be918c8b0df8aa3c</hosted_login_token>
56
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
57
+ <state>active</state>
58
+ </account>
59
+
60
+ http_version: "1.1"
61
+ - !ruby/struct:VCR::HTTPInteraction
62
+ request: !ruby/struct:VCR::Request
42
63
  method: :post
43
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
44
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit>\n <amount-in-cents
45
- type=\"integer\">100</amount-in-cents>\n <description>one</description>\n</credit>\n"
46
- headers:
47
- user-agent:
48
- - Recurly Ruby Client v0.4.10
49
- content-type:
64
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
65
+ body: |
66
+ <?xml version="1.0" encoding="UTF-8"?>
67
+ <credit>
68
+ <amount-in-cents type="integer">100</amount-in-cents>
69
+ <description>one</description>
70
+ </credit>
71
+
72
+ headers:
73
+ user-agent:
74
+ - Recurly Ruby Client v0.4.13
75
+ content-type:
50
76
  - application/xml
51
- response: !ruby/struct:VCR::Response
52
- status: !ruby/struct:VCR::ResponseStatus
77
+ response: !ruby/struct:VCR::Response
78
+ status: !ruby/struct:VCR::ResponseStatus
53
79
  code: 201
54
80
  message: Created
55
- headers:
56
- content-type:
81
+ headers:
82
+ content-type:
57
83
  - application/xml; charset=utf-8
58
- cache-control:
84
+ cache-control:
59
85
  - no-cache
60
- x-ua-compatible:
86
+ x-ua-compatible:
61
87
  - IE=Edge
62
- set-cookie:
63
- - _recurly_session=58af0dbbe55790deb091b64c2a3438c5; domain=.lvh.me; path=/;
64
- HttpOnly
65
- server:
88
+ set-cookie:
89
+ - _recurly_session=74d0affabe94074fa1b417842fa52db7; domain=.lvh.me; path=/; HttpOnly
90
+ server:
66
91
  - thin 1.2.11 codename Bat-Shit Crazy
67
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit type=\"credit\">\n
68
- \ <id>417eec6369334b38bad0f1a6f6fcd024</id>\n <account_code>credit-list-1313708090</account_code>\n
69
- \ <quantity type=\"integer\">1</quantity>\n <unit_amount_in_cents type=\"integer\">-100</unit_amount_in_cents>\n
70
- \ <amount_in_cents type=\"integer\">-100</amount_in_cents>\n <currency>USD</currency>\n
71
- \ <start_date type=\"datetime\">2011-08-19T20:01:45Z</start_date>\n <end_date
72
- nil=\"true\" type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
73
- \ <description>one</description>\n <created_at type=\"datetime\">2011-08-19T20:01:45Z</created_at>\n</credit>\n"
74
- http_version: '1.1'
75
- - !ruby/struct:VCR::HTTPInteraction
76
- request: !ruby/struct:VCR::Request
92
+ body: |
93
+ <?xml version="1.0" encoding="UTF-8"?>
94
+ <credit type="credit">
95
+ <id>95ff2af7afd2483c97e3e1108d067c9c</id>
96
+ <account_code>credit-list-1313708090</account_code>
97
+ <quantity type="integer">1</quantity>
98
+ <unit_amount_in_cents type="integer">-100</unit_amount_in_cents>
99
+ <amount_in_cents type="integer">-100</amount_in_cents>
100
+ <currency>USD</currency>
101
+ <start_date type="datetime">2011-09-22T22:01:47Z</start_date>
102
+ <end_date nil="true" type="datetime"></end_date>
103
+ <invoice_number nil="true" type="integer"></invoice_number>
104
+ <description>one</description>
105
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
106
+ </credit>
107
+
108
+ http_version: "1.1"
109
+ - !ruby/struct:VCR::HTTPInteraction
110
+ request: !ruby/struct:VCR::Request
77
111
  method: :post
78
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
79
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit>\n <amount-in-cents
80
- type=\"integer\">200</amount-in-cents>\n <description>two</description>\n</credit>\n"
81
- headers:
82
- user-agent:
83
- - Recurly Ruby Client v0.4.10
84
- content-type:
112
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
113
+ body: |
114
+ <?xml version="1.0" encoding="UTF-8"?>
115
+ <credit>
116
+ <amount-in-cents type="integer">200</amount-in-cents>
117
+ <description>two</description>
118
+ </credit>
119
+
120
+ headers:
121
+ user-agent:
122
+ - Recurly Ruby Client v0.4.13
123
+ content-type:
85
124
  - application/xml
86
- response: !ruby/struct:VCR::Response
87
- status: !ruby/struct:VCR::ResponseStatus
125
+ response: !ruby/struct:VCR::Response
126
+ status: !ruby/struct:VCR::ResponseStatus
88
127
  code: 201
89
128
  message: Created
90
- headers:
91
- content-type:
129
+ headers:
130
+ content-type:
92
131
  - application/xml; charset=utf-8
93
- cache-control:
132
+ cache-control:
94
133
  - no-cache
95
- x-ua-compatible:
134
+ x-ua-compatible:
96
135
  - IE=Edge
97
- set-cookie:
98
- - _recurly_session=1a6f6d8598af7c2a4f98f679d4d4d68d; domain=.lvh.me; path=/;
99
- HttpOnly
100
- server:
136
+ set-cookie:
137
+ - _recurly_session=454ddd4b98d61f31b09757ba970cb35b; domain=.lvh.me; path=/; HttpOnly
138
+ server:
101
139
  - thin 1.2.11 codename Bat-Shit Crazy
102
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit type=\"credit\">\n
103
- \ <id>1d3f91b5576d40749bc2f1214e0be882</id>\n <account_code>credit-list-1313708090</account_code>\n
104
- \ <quantity type=\"integer\">1</quantity>\n <unit_amount_in_cents type=\"integer\">-200</unit_amount_in_cents>\n
105
- \ <amount_in_cents type=\"integer\">-200</amount_in_cents>\n <currency>USD</currency>\n
106
- \ <start_date type=\"datetime\">2011-08-19T20:01:45Z</start_date>\n <end_date
107
- nil=\"true\" type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
108
- \ <description>two</description>\n <created_at type=\"datetime\">2011-08-19T20:01:45Z</created_at>\n</credit>\n"
109
- http_version: '1.1'
110
- - !ruby/struct:VCR::HTTPInteraction
111
- request: !ruby/struct:VCR::Request
140
+ body: |
141
+ <?xml version="1.0" encoding="UTF-8"?>
142
+ <credit type="credit">
143
+ <id>21dd23cba98a482fb6bb352199aa60db</id>
144
+ <account_code>credit-list-1313708090</account_code>
145
+ <quantity type="integer">1</quantity>
146
+ <unit_amount_in_cents type="integer">-200</unit_amount_in_cents>
147
+ <amount_in_cents type="integer">-200</amount_in_cents>
148
+ <currency>USD</currency>
149
+ <start_date type="datetime">2011-09-22T22:01:47Z</start_date>
150
+ <end_date nil="true" type="datetime"></end_date>
151
+ <invoice_number nil="true" type="integer"></invoice_number>
152
+ <description>two</description>
153
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
154
+ </credit>
155
+
156
+ http_version: "1.1"
157
+ - !ruby/struct:VCR::HTTPInteraction
158
+ request: !ruby/struct:VCR::Request
112
159
  method: :post
113
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
114
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit>\n <amount-in-cents
115
- type=\"integer\">300</amount-in-cents>\n <description>three</description>\n</credit>\n"
116
- headers:
117
- user-agent:
118
- - Recurly Ruby Client v0.4.10
119
- content-type:
160
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
161
+ body: |
162
+ <?xml version="1.0" encoding="UTF-8"?>
163
+ <credit>
164
+ <amount-in-cents type="integer">300</amount-in-cents>
165
+ <description>three</description>
166
+ </credit>
167
+
168
+ headers:
169
+ user-agent:
170
+ - Recurly Ruby Client v0.4.13
171
+ content-type:
120
172
  - application/xml
121
- response: !ruby/struct:VCR::Response
122
- status: !ruby/struct:VCR::ResponseStatus
173
+ response: !ruby/struct:VCR::Response
174
+ status: !ruby/struct:VCR::ResponseStatus
123
175
  code: 201
124
176
  message: Created
125
- headers:
126
- content-type:
177
+ headers:
178
+ content-type:
127
179
  - application/xml; charset=utf-8
128
- cache-control:
180
+ cache-control:
129
181
  - no-cache
130
- x-ua-compatible:
182
+ x-ua-compatible:
131
183
  - IE=Edge
132
- set-cookie:
133
- - _recurly_session=8c5aa5194e3fcaac81d753f9afff9deb; domain=.lvh.me; path=/;
134
- HttpOnly
135
- server:
184
+ set-cookie:
185
+ - _recurly_session=12b8e65d08b98514359d11454368ec54; domain=.lvh.me; path=/; HttpOnly
186
+ server:
136
187
  - thin 1.2.11 codename Bat-Shit Crazy
137
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credit type=\"credit\">\n
138
- \ <id>b3a613670f1e4bdcafa1233dabd991cb</id>\n <account_code>credit-list-1313708090</account_code>\n
139
- \ <quantity type=\"integer\">1</quantity>\n <unit_amount_in_cents type=\"integer\">-300</unit_amount_in_cents>\n
140
- \ <amount_in_cents type=\"integer\">-300</amount_in_cents>\n <currency>USD</currency>\n
141
- \ <start_date type=\"datetime\">2011-08-19T20:01:45Z</start_date>\n <end_date
142
- nil=\"true\" type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
143
- \ <description>three</description>\n <created_at type=\"datetime\">2011-08-19T20:01:45Z</created_at>\n</credit>\n"
144
- http_version: '1.1'
145
- - !ruby/struct:VCR::HTTPInteraction
146
- request: !ruby/struct:VCR::Request
188
+ body: |
189
+ <?xml version="1.0" encoding="UTF-8"?>
190
+ <credit type="credit">
191
+ <id>40308b4027c54cd994c36c718f6bfa54</id>
192
+ <account_code>credit-list-1313708090</account_code>
193
+ <quantity type="integer">1</quantity>
194
+ <unit_amount_in_cents type="integer">-300</unit_amount_in_cents>
195
+ <amount_in_cents type="integer">-300</amount_in_cents>
196
+ <currency>USD</currency>
197
+ <start_date type="datetime">2011-09-22T22:01:47Z</start_date>
198
+ <end_date nil="true" type="datetime"></end_date>
199
+ <invoice_number nil="true" type="integer"></invoice_number>
200
+ <description>three</description>
201
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
202
+ </credit>
203
+
204
+ http_version: "1.1"
205
+ - !ruby/struct:VCR::HTTPInteraction
206
+ request: !ruby/struct:VCR::Request
147
207
  method: :get
148
- uri: http://api-test%40facebook-test.com:69d95a9768c745ecb5ac6864032ec970@app.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
149
- body: !!null
150
- headers:
151
- user-agent:
152
- - Recurly Ruby Client v0.4.10
153
- accept:
208
+ uri: http://2a655d41659d4ae0b37fcaec06331bf5:@api.lvh.me:3000/accounts/credit-list-1313708090/credits.xml
209
+ body:
210
+ headers:
211
+ user-agent:
212
+ - Recurly Ruby Client v0.4.13
213
+ accept:
154
214
  - application/xml
155
- accept-encoding:
215
+ accept-encoding:
156
216
  - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
157
- response: !ruby/struct:VCR::Response
158
- status: !ruby/struct:VCR::ResponseStatus
217
+ response: !ruby/struct:VCR::Response
218
+ status: !ruby/struct:VCR::ResponseStatus
159
219
  code: 200
160
220
  message: OK
161
- headers:
162
- content-type:
221
+ headers:
222
+ content-type:
163
223
  - application/xml; charset=utf-8
164
- etag:
165
- - ! '"e5e7df3b547356c3e3c337ddc4dcee99"'
166
- cache-control:
224
+ etag:
225
+ - "\"090f0ebf081471c2df82186a16bfd952\""
226
+ cache-control:
167
227
  - max-age=0, private, must-revalidate
168
- x-ua-compatible:
228
+ x-ua-compatible:
169
229
  - IE=Edge
170
- set-cookie:
171
- - _recurly_session=4569ec689a06e3a53422d12e394d0243; domain=.lvh.me; path=/;
172
- HttpOnly
173
- server:
230
+ server:
174
231
  - thin 1.2.11 codename Bat-Shit Crazy
175
- body: ! "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<credits type=\"array\">\n
176
- \ <credit type=\"credit\">\n <id>b3a613670f1e4bdcafa1233dabd991cb</id>\n
177
- \ <account_code>credit-list-1313708090</account_code>\n <quantity type=\"integer\">1</quantity>\n
178
- \ <unit_amount_in_cents type=\"integer\">-300</unit_amount_in_cents>\n <amount_in_cents
179
- type=\"integer\">-300</amount_in_cents>\n <currency>USD</currency>\n <start_date
180
- type=\"datetime\">2011-08-19T20:01:45Z</start_date>\n <end_date nil=\"true\"
181
- type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
182
- \ <description>three</description>\n <created_at type=\"datetime\">2011-08-19T20:01:45Z</created_at>\n
183
- \ </credit>\n <credit type=\"credit\">\n <id>1d3f91b5576d40749bc2f1214e0be882</id>\n
184
- \ <account_code>credit-list-1313708090</account_code>\n <quantity type=\"integer\">1</quantity>\n
185
- \ <unit_amount_in_cents type=\"integer\">-200</unit_amount_in_cents>\n <amount_in_cents
186
- type=\"integer\">-200</amount_in_cents>\n <currency>USD</currency>\n <start_date
187
- type=\"datetime\">2011-08-19T20:01:45Z</start_date>\n <end_date nil=\"true\"
188
- type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
189
- \ <description>two</description>\n <created_at type=\"datetime\">2011-08-19T20:01:45Z</created_at>\n
190
- \ </credit>\n <credit type=\"credit\">\n <id>417eec6369334b38bad0f1a6f6fcd024</id>\n
191
- \ <account_code>credit-list-1313708090</account_code>\n <quantity type=\"integer\">1</quantity>\n
192
- \ <unit_amount_in_cents type=\"integer\">-100</unit_amount_in_cents>\n <amount_in_cents
193
- type=\"integer\">-100</amount_in_cents>\n <currency>USD</currency>\n <start_date
194
- type=\"datetime\">2011-08-19T20:01:45Z</start_date>\n <end_date nil=\"true\"
195
- type=\"datetime\"></end_date>\n <invoice_number nil=\"true\" type=\"integer\"></invoice_number>\n
196
- \ <description>one</description>\n <created_at type=\"datetime\">2011-08-19T20:01:45Z</created_at>\n
197
- \ </credit>\n</credits>\n"
198
- http_version: '1.1'
232
+ body: |
233
+ <?xml version="1.0" encoding="UTF-8"?>
234
+ <credits type="array">
235
+ <credit type="credit">
236
+ <id>40308b4027c54cd994c36c718f6bfa54</id>
237
+ <account_code>credit-list-1313708090</account_code>
238
+ <quantity type="integer">1</quantity>
239
+ <unit_amount_in_cents type="integer">-300</unit_amount_in_cents>
240
+ <amount_in_cents type="integer">-300</amount_in_cents>
241
+ <currency>USD</currency>
242
+ <start_date type="datetime">2011-09-22T22:01:47Z</start_date>
243
+ <end_date nil="true" type="datetime"></end_date>
244
+ <invoice_number nil="true" type="integer"></invoice_number>
245
+ <description>three</description>
246
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
247
+ </credit>
248
+ <credit type="credit">
249
+ <id>21dd23cba98a482fb6bb352199aa60db</id>
250
+ <account_code>credit-list-1313708090</account_code>
251
+ <quantity type="integer">1</quantity>
252
+ <unit_amount_in_cents type="integer">-200</unit_amount_in_cents>
253
+ <amount_in_cents type="integer">-200</amount_in_cents>
254
+ <currency>USD</currency>
255
+ <start_date type="datetime">2011-09-22T22:01:47Z</start_date>
256
+ <end_date nil="true" type="datetime"></end_date>
257
+ <invoice_number nil="true" type="integer"></invoice_number>
258
+ <description>two</description>
259
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
260
+ </credit>
261
+ <credit type="credit">
262
+ <id>95ff2af7afd2483c97e3e1108d067c9c</id>
263
+ <account_code>credit-list-1313708090</account_code>
264
+ <quantity type="integer">1</quantity>
265
+ <unit_amount_in_cents type="integer">-100</unit_amount_in_cents>
266
+ <amount_in_cents type="integer">-100</amount_in_cents>
267
+ <currency>USD</currency>
268
+ <start_date type="datetime">2011-09-22T22:01:47Z</start_date>
269
+ <end_date nil="true" type="datetime"></end_date>
270
+ <invoice_number nil="true" type="integer"></invoice_number>
271
+ <description>one</description>
272
+ <created_at type="datetime">2011-09-22T22:01:47Z</created_at>
273
+ </credit>
274
+ </credits>
275
+
276
+ http_version: "1.1"