recurly 0.3.2 → 0.3.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.
- data/LICENSE +1 -1
- data/README.md +4 -4
- data/lib/recurly.rb +8 -1
- data/lib/recurly/account.rb +5 -0
- data/lib/recurly/coupon.rb +5 -0
- data/lib/recurly/rails3/recurly.rake +3 -18
- data/lib/recurly/version.rb +1 -1
- data/spec/config/{test.yml → test1.yml} +0 -0
- data/spec/config/test2.yml +9 -0
- data/spec/integration/account_spec.rb +3 -3
- data/spec/integration/billing_info_spec.rb +4 -8
- data/spec/integration/coupon_spec.rb +49 -0
- data/spec/integration/plan_spec.rb +0 -28
- data/spec/integration/transaction_spec.rb +3 -3
- data/spec/spec_helper.rb +6 -0
- data/spec/support/factory.rb +1 -1
- data/spec/unit/config_spec.rb +9 -2
- data/spec/vcr/account/accept-language-account/{1294473653.yml → 1296674173.yml} +29 -27
- data/spec/vcr/account/close/{1294473761.yml → 1296674173.yml} +71 -67
- data/spec/vcr/account/create-blank/{1294473761.yml → 1296674173.yml} +20 -18
- data/spec/vcr/account/create-duplicate/{1294473761.yml → 1296674173.yml} +42 -38
- data/spec/vcr/account/create-min/{1294473761.yml → 1296674173.yml} +26 -24
- data/spec/vcr/account/create/{1294473761.yml → 1296674173.yml} +29 -27
- data/spec/vcr/account/find/{1294473761.yml → 1296674173.yml} +71 -63
- data/spec/vcr/account/list/1296674173.yml +55 -0
- data/spec/vcr/account/update/{1294473761.yml → 1296674173.yml} +113 -107
- data/spec/vcr/billing/create/{1286682213.yml → 1296690812.yml} +86 -82
- data/spec/vcr/billing/destroy/{1286682213.yml → 1296690812.yml} +126 -142
- data/spec/vcr/billing/find/{1286682213.yml → 1296690812.yml} +115 -109
- data/spec/vcr/billing/update/{1286682213.yml → 1296690812.yml} +119 -115
- data/spec/vcr/charge/create/{1287465632.yml → 1296674173.yml} +109 -103
- data/spec/vcr/charge/delete-uninvoiced/{1287465632.yml → 1296674173.yml} +129 -117
- data/spec/vcr/charge/list-all/{1287465632.yml → 1296674173.yml} +131 -121
- data/spec/vcr/charge/list-invoiced/{1287465632.yml → 1296674173.yml} +195 -177
- data/spec/vcr/charge/list-pending/{1287465632.yml → 1296674173.yml} +131 -121
- data/spec/vcr/charge/lookup/{1287465632.yml → 1296674173.yml} +77 -71
- data/spec/vcr/coupon/create/1296688818.yml +183 -0
- data/spec/vcr/coupon/create/1296774903.yml +183 -0
- data/spec/vcr/coupon/destroy/1296688818.yml +207 -0
- data/spec/vcr/coupon/destroy/1296774903.yml +207 -0
- data/spec/vcr/credit/create/1296674173.yml +121 -0
- data/spec/vcr/credit/delete/1296674173.yml +121 -0
- data/spec/vcr/credit/list/1296674173.yml +121 -0
- data/spec/vcr/credit/lookup/1296674173.yml +121 -0
- data/spec/vcr/invoice/create-no-charges/{1287167121.yml → 1296674173.yml} +79 -75
- data/spec/vcr/invoice/create/{1287167121.yml → 1296674173.yml} +141 -130
- data/spec/vcr/invoice/list/{1287167121.yml → 1296674173.yml} +196 -180
- data/spec/vcr/invoice/lookup/{1287167121.yml → 1296674173.yml} +145 -133
- data/spec/vcr/plan/all.yml +86 -136
- data/spec/vcr/plan/delete/{1286677585.yml → 1296674173.yml} +87 -79
- data/spec/vcr/plan/find.yml +73 -91
- data/spec/vcr/plan/update.yml +80 -76
- data/spec/vcr/subscription/addons/add/1296674173.yml +225 -0
- data/spec/vcr/subscription/addons/create/1296674173.yml +225 -0
- data/spec/vcr/subscription/addons/remove/1296674173.yml +225 -0
- data/spec/vcr/subscription/cancel-with-code/{1287455769.yml → 1296674173.yml} +201 -201
- data/spec/vcr/subscription/cancel/{1287455769.yml → 1296674173.yml} +173 -175
- data/spec/vcr/subscription/change1/{1287455769.yml → 1296674173.yml} +172 -174
- data/spec/vcr/subscription/change2/{1287455769.yml → 1296674173.yml} +172 -174
- data/spec/vcr/subscription/create/{1287455769.yml → 1296674173.yml} +93 -99
- data/spec/vcr/subscription/find/{1287455769.yml → 1296674173.yml} +119 -123
- data/spec/vcr/subscription/reactivate/{1287455769.yml → 1296674173.yml} +194 -196
- data/spec/vcr/subscription/{refund-none/1287455769.yml → refund-full/1296674173.yml} +162 -162
- data/spec/vcr/subscription/{refund-full/1287455769.yml → refund-none/1296674173.yml} +162 -162
- data/spec/vcr/subscription/refund-partial/{1287455769.yml → 1296674173.yml} +162 -162
- data/spec/vcr/transaction/all/{1289558212.yml → 1296674173.yml} +155 -153
- data/spec/vcr/transaction/create-no-account/{1289558212.yml → 1296674173.yml} +37 -35
- data/spec/vcr/transaction/create-with-account/{1289558212.yml → 1296674173.yml} +91 -87
- data/spec/vcr/transaction/list-filled/{1289558212.yml → 1296674173.yml} +200 -190
- data/spec/vcr/transaction/list-initial/{1289558212.yml → 1296674173.yml} +92 -88
- data/spec/vcr/transaction/lookup/{1289558212.yml → 1296674173.yml} +241 -227
- data/spec/vcr/transaction/refund/{1289558212.yml → 1296674173.yml} +119 -115
- data/spec/vcr/transaction/void/1296674173.yml +352 -0
- metadata +122 -122
- data/spec/config/recurly.yml +0 -4
- data/spec/vcr/account/accept-language-account/1294473761.yml +0 -68
- data/spec/vcr/account/accept-language/1294473117.yml +0 -167
- data/spec/vcr/account/list/1294473761.yml +0 -1597
- data/spec/vcr/credit/create/1287461400.yml +0 -174
- data/spec/vcr/credit/delete/1287461400.yml +0 -249
- data/spec/vcr/credit/list/1287461400.yml +0 -306
- data/spec/vcr/credit/lookup/1287461400.yml +0 -174
- data/spec/vcr/subscription/addons/add/1292420980.yml +0 -479
- data/spec/vcr/subscription/addons/create/1292420980.yml +0 -318
- data/spec/vcr/subscription/addons/remove/1292420980.yml +0 -448
- data/spec/vcr/transaction/void/1289558212.yml +0 -601
@@ -2,57 +2,59 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/accounts.xml
|
6
6
|
body: |
|
7
7
|
<?xml version="1.0" encoding="UTF-8"?>
|
8
8
|
<account>
|
9
|
-
<
|
10
|
-
<
|
9
|
+
<account-code>subscription-create-1296674173</account-code>
|
10
|
+
<first-name>Verena</first-name>
|
11
11
|
<last-name>Test</last-name>
|
12
|
-
<accept-language type="yaml" nil="true"></accept-language>
|
13
12
|
<email>verena@test.com</email>
|
14
|
-
<
|
13
|
+
<company-name>Recurly Ruby Gem</company-name>
|
14
|
+
<accept-language type="yaml" nil="true"></accept-language>
|
15
15
|
</account>
|
16
16
|
|
17
17
|
headers:
|
18
|
+
authorization:
|
19
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
20
|
+
content-type:
|
21
|
+
- application/xml
|
18
22
|
accept:
|
19
23
|
- "*/*"
|
24
|
+
user-agent:
|
25
|
+
- Ruby
|
20
26
|
connection:
|
21
27
|
- close
|
22
|
-
content-type:
|
23
|
-
- application/xml
|
24
|
-
authorization:
|
25
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
26
28
|
response: !ruby/struct:VCR::Response
|
27
29
|
status: !ruby/struct:VCR::ResponseStatus
|
28
30
|
code: 201
|
29
|
-
message: Created
|
31
|
+
message: "Created "
|
30
32
|
headers:
|
33
|
+
cache-control:
|
34
|
+
- no-cache
|
31
35
|
location:
|
32
|
-
-
|
33
|
-
|
34
|
-
-
|
36
|
+
- http://litle-test.recurly.local:3000/accounts/subscription-create-1296674173
|
37
|
+
x-runtime:
|
38
|
+
- "677"
|
35
39
|
content-type:
|
36
40
|
- application/xml; charset=utf-8
|
37
|
-
x-runtime:
|
38
|
-
- "348"
|
39
|
-
date:
|
40
|
-
- Sat, 08 Jan 2011 08:05:27 GMT
|
41
|
-
server:
|
42
|
-
- nginx/0.8.53
|
43
41
|
content-length:
|
44
42
|
- "593"
|
43
|
+
server:
|
44
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
45
|
+
date:
|
46
|
+
- Thu, 03 Feb 2011 22:21:22 GMT
|
47
|
+
connection:
|
48
|
+
- close
|
45
49
|
set-cookie:
|
46
|
-
- account_credentials=
|
50
|
+
- account_credentials=e930e8e5945b340ca1363f7cb89427ae095ab2842e5fcd35a36c42621f3cf29e702e215f0a88069a77248861ce9e657807470bea649dafc07dae1e6649cc3b8e%3A%3A; domain=.recurly.local; path=/
|
47
51
|
- ""
|
48
|
-
- _recurly_session=
|
49
|
-
cache-control:
|
50
|
-
- no-cache
|
52
|
+
- _recurly_session=4905f21b683565d80c142104d3ce6617; domain=.recurly.local; path=/; HttpOnly
|
51
53
|
body: |
|
52
54
|
<?xml version="1.0" encoding="UTF-8"?>
|
53
55
|
<account>
|
54
|
-
<id>subscription-create-
|
55
|
-
<account_code>subscription-create-
|
56
|
+
<id>subscription-create-1296674173</id>
|
57
|
+
<account_code>subscription-create-1296674173</account_code>
|
56
58
|
<username></username>
|
57
59
|
<email>verena@test.com</email>
|
58
60
|
<first_name>Verena</first_name>
|
@@ -60,8 +62,8 @@
|
|
60
62
|
<company_name>Recurly Ruby Gem</company_name>
|
61
63
|
<balance_in_cents type="integer">0</balance_in_cents>
|
62
64
|
<closed type="boolean">false</closed>
|
63
|
-
<hosted_login_token>
|
64
|
-
<created_at type="datetime">2011-
|
65
|
+
<hosted_login_token>2671312c43ab480db35b87f6e36b248d</hosted_login_token>
|
66
|
+
<created_at type="datetime">2011-02-03T22:21:22Z</created_at>
|
65
67
|
<state>active</state>
|
66
68
|
</account>
|
67
69
|
|
@@ -69,40 +71,42 @@
|
|
69
71
|
- !ruby/struct:VCR::HTTPInteraction
|
70
72
|
request: !ruby/struct:VCR::Request
|
71
73
|
method: :get
|
72
|
-
uri:
|
74
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/company/plans/paid.xml
|
73
75
|
body:
|
74
76
|
headers:
|
77
|
+
authorization:
|
78
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
75
79
|
accept:
|
76
80
|
- application/xml
|
81
|
+
accept-encoding:
|
82
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
83
|
+
user-agent:
|
84
|
+
- Ruby
|
77
85
|
connection:
|
78
86
|
- close
|
79
|
-
authorization:
|
80
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
81
87
|
response: !ruby/struct:VCR::Response
|
82
88
|
status: !ruby/struct:VCR::ResponseStatus
|
83
89
|
code: 200
|
84
|
-
message: OK
|
90
|
+
message: "OK "
|
85
91
|
headers:
|
86
|
-
x-
|
87
|
-
-
|
88
|
-
etag:
|
89
|
-
- "\"47a9e8e85691ef0600a2dd39f113a21e\""
|
90
|
-
connection:
|
91
|
-
- close
|
92
|
+
x-runtime:
|
93
|
+
- "228"
|
92
94
|
content-type:
|
93
95
|
- application/xml; charset=utf-8
|
94
|
-
|
95
|
-
- "
|
96
|
-
date:
|
97
|
-
- Sat, 08 Jan 2011 08:05:28 GMT
|
98
|
-
server:
|
99
|
-
- nginx/0.8.53
|
100
|
-
content-length:
|
101
|
-
- "1564"
|
102
|
-
set-cookie:
|
103
|
-
- _recurly_session=b19a7b6ddfdefde20c685afce0c8d1f8; domain=.recurly.com; path=/; secure; HttpOnly
|
96
|
+
etag:
|
97
|
+
- "\"70b5c605373b1a4346a2d7ed46048dc4\""
|
104
98
|
cache-control:
|
105
99
|
- private, max-age=0, must-revalidate
|
100
|
+
content-length:
|
101
|
+
- "1150"
|
102
|
+
server:
|
103
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
104
|
+
date:
|
105
|
+
- Thu, 03 Feb 2011 22:21:24 GMT
|
106
|
+
connection:
|
107
|
+
- close
|
108
|
+
set-cookie:
|
109
|
+
- _recurly_session=037630ba6409d8527fb63a9b08e18299; domain=.recurly.local; path=/; HttpOnly
|
106
110
|
body: |
|
107
111
|
<?xml version="1.0" encoding="UTF-8"?>
|
108
112
|
<plan>
|
@@ -111,7 +115,7 @@
|
|
111
115
|
<description></description>
|
112
116
|
<success_url></success_url>
|
113
117
|
<cancel_url></cancel_url>
|
114
|
-
<created_at type="datetime">
|
118
|
+
<created_at type="datetime">2011-02-02T21:02:59Z</created_at>
|
115
119
|
<unit_amount_in_cents type="integer">1000</unit_amount_in_cents>
|
116
120
|
<setup_fee_in_cents type="integer">0</setup_fee_in_cents>
|
117
121
|
<plan_interval_length type="integer">1</plan_interval_length>
|
@@ -126,99 +130,89 @@
|
|
126
130
|
<plan_interval_unit>months</plan_interval_unit>
|
127
131
|
<trial_interval_length type="integer">0</trial_interval_length>
|
128
132
|
<trial_interval_unit>months</trial_interval_unit>
|
129
|
-
<created_at type="datetime">
|
133
|
+
<created_at type="datetime">2011-02-02T21:02:59Z</created_at>
|
130
134
|
</latest_version>
|
131
|
-
<add_ons type="collection">
|
132
|
-
<add_on>
|
133
|
-
<add_on_code>special</add_on_code>
|
134
|
-
<default_unit_amount_in_cents>1000</default_unit_amount_in_cents>
|
135
|
-
<default_quantity>1</default_quantity>
|
136
|
-
</add_on>
|
137
|
-
<add_on>
|
138
|
-
<add_on_code>special2</add_on_code>
|
139
|
-
<default_unit_amount_in_cents>1500</default_unit_amount_in_cents>
|
140
|
-
<default_quantity>1</default_quantity>
|
141
|
-
</add_on>
|
142
|
-
</add_ons>
|
143
135
|
</plan>
|
144
136
|
|
145
137
|
http_version: "1.1"
|
146
138
|
- !ruby/struct:VCR::HTTPInteraction
|
147
139
|
request: !ruby/struct:VCR::Request
|
148
140
|
method: :post
|
149
|
-
uri:
|
141
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/accounts/subscription-create-1296674173/subscription.xml
|
150
142
|
body: |
|
151
143
|
<?xml version="1.0" encoding="UTF-8"?>
|
152
144
|
<subscription>
|
153
|
-
<quantity type="integer">1</quantity>
|
154
145
|
<plan-code>paid</plan-code>
|
146
|
+
<quantity type="integer">1</quantity>
|
155
147
|
<account>
|
156
|
-
<
|
157
|
-
<
|
158
|
-
<company-name>Recurly Ruby Gem</company-name>
|
159
|
-
<account-code>subscription-create-1287455769</account-code>
|
160
|
-
<closed type="boolean">false</closed>
|
161
|
-
<username type="yaml" nil="true"></username>
|
162
|
-
<id>subscription-create-1287455769</id>
|
148
|
+
<account-code>subscription-create-1296674173</account-code>
|
149
|
+
<first-name>Verena</first-name>
|
163
150
|
<last-name>Test</last-name>
|
151
|
+
<email>verena@test.com</email>
|
152
|
+
<company-name>Recurly Ruby Gem</company-name>
|
164
153
|
<accept-language type="yaml" nil="true"></accept-language>
|
154
|
+
<id>subscription-create-1296674173</id>
|
155
|
+
<username type="yaml" nil="true"></username>
|
156
|
+
<balance-in-cents type="integer">0</balance-in-cents>
|
157
|
+
<closed type="boolean">false</closed>
|
158
|
+
<hosted-login-token>2671312c43ab480db35b87f6e36b248d</hosted-login-token>
|
159
|
+
<created-at type="datetime">2011-02-03T22:21:22Z</created-at>
|
160
|
+
<state>active</state>
|
165
161
|
<billing-info>
|
166
162
|
<address1>123 Test St</address1>
|
167
163
|
<city>San Francisco</city>
|
164
|
+
<state>CA</state>
|
168
165
|
<zip>94115</zip>
|
169
166
|
<country>US</country>
|
170
167
|
<credit-card>
|
171
|
-
<number>
|
172
|
-
<month type="integer">1</month>
|
168
|
+
<number>4111111111111111</number>
|
173
169
|
<year type="integer">2012</year>
|
170
|
+
<month type="integer">2</month>
|
174
171
|
<verification-value>123</verification-value>
|
175
172
|
</credit-card>
|
176
|
-
<last-name>Test</last-name>
|
177
173
|
<first-name>Verena</first-name>
|
178
|
-
<
|
174
|
+
<last-name>Test</last-name>
|
179
175
|
</billing-info>
|
180
|
-
<balance-in-cents type="integer">0</balance-in-cents>
|
181
|
-
<state>active</state>
|
182
|
-
<email>verena@test.com</email>
|
183
|
-
<first-name>Verena</first-name>
|
184
176
|
</account>
|
185
177
|
</subscription>
|
186
178
|
|
187
179
|
headers:
|
180
|
+
authorization:
|
181
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
182
|
+
content-type:
|
183
|
+
- application/xml
|
188
184
|
accept:
|
189
185
|
- "*/*"
|
186
|
+
user-agent:
|
187
|
+
- Ruby
|
190
188
|
connection:
|
191
189
|
- close
|
192
|
-
content-type:
|
193
|
-
- application/xml
|
194
|
-
authorization:
|
195
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
196
190
|
response: !ruby/struct:VCR::Response
|
197
191
|
status: !ruby/struct:VCR::ResponseStatus
|
198
192
|
code: 201
|
199
|
-
message: Created
|
193
|
+
message: "Created "
|
200
194
|
headers:
|
201
|
-
|
202
|
-
-
|
195
|
+
cache-control:
|
196
|
+
- no-cache
|
197
|
+
x-runtime:
|
198
|
+
- "4415"
|
203
199
|
content-type:
|
204
200
|
- application/xml; charset=utf-8
|
205
|
-
x-runtime:
|
206
|
-
- "472"
|
207
|
-
date:
|
208
|
-
- Sat, 08 Jan 2011 08:05:29 GMT
|
209
|
-
server:
|
210
|
-
- nginx/0.8.53
|
211
201
|
content-length:
|
212
202
|
- "908"
|
203
|
+
server:
|
204
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
205
|
+
date:
|
206
|
+
- Thu, 03 Feb 2011 22:21:30 GMT
|
207
|
+
connection:
|
208
|
+
- close
|
213
209
|
set-cookie:
|
214
|
-
- _recurly_session=
|
215
|
-
cache-control:
|
216
|
-
- no-cache
|
210
|
+
- _recurly_session=d6d44d6c660ba704ad326858053c25ee; domain=.recurly.local; path=/; HttpOnly
|
217
211
|
body: |
|
218
212
|
<?xml version="1.0" encoding="UTF-8"?>
|
219
213
|
<subscription>
|
220
|
-
<id>subscription-create-
|
221
|
-
<account_code>subscription-create-
|
214
|
+
<id>subscription-create-1296674173</id>
|
215
|
+
<account_code>subscription-create-1296674173</account_code>
|
222
216
|
<plan>
|
223
217
|
<plan_code>paid</plan_code>
|
224
218
|
<name>Paid</name>
|
@@ -226,11 +220,11 @@
|
|
226
220
|
<state>active</state>
|
227
221
|
<quantity type="integer">1</quantity>
|
228
222
|
<total_amount_in_cents type="integer">1000</total_amount_in_cents>
|
229
|
-
<activated_at type="datetime">2011-
|
223
|
+
<activated_at type="datetime">2011-02-03T22:21:26Z</activated_at>
|
230
224
|
<canceled_at nil="true" type="datetime"></canceled_at>
|
231
225
|
<expires_at nil="true" type="datetime"></expires_at>
|
232
|
-
<current_period_started_at type="datetime">2011-
|
233
|
-
<current_period_ends_at type="datetime">2011-
|
226
|
+
<current_period_started_at type="datetime">2011-02-03T22:21:26Z</current_period_started_at>
|
227
|
+
<current_period_ends_at type="datetime">2011-03-03T22:21:26Z</current_period_ends_at>
|
234
228
|
<trial_started_at nil="true" type="datetime"></trial_started_at>
|
235
229
|
<trial_ends_at nil="true" type="datetime"></trial_ends_at>
|
236
230
|
<add_ons type="array">
|
@@ -2,57 +2,59 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/accounts.xml
|
6
6
|
body: |
|
7
7
|
<?xml version="1.0" encoding="UTF-8"?>
|
8
8
|
<account>
|
9
|
-
<
|
10
|
-
<
|
9
|
+
<account-code>subscription-find-1296674173</account-code>
|
10
|
+
<first-name>Verena</first-name>
|
11
11
|
<last-name>Test</last-name>
|
12
|
-
<accept-language type="yaml" nil="true"></accept-language>
|
13
12
|
<email>verena@test.com</email>
|
14
|
-
<
|
13
|
+
<company-name>Recurly Ruby Gem</company-name>
|
14
|
+
<accept-language type="yaml" nil="true"></accept-language>
|
15
15
|
</account>
|
16
16
|
|
17
17
|
headers:
|
18
|
+
authorization:
|
19
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
20
|
+
content-type:
|
21
|
+
- application/xml
|
18
22
|
accept:
|
19
23
|
- "*/*"
|
24
|
+
user-agent:
|
25
|
+
- Ruby
|
20
26
|
connection:
|
21
27
|
- close
|
22
|
-
content-type:
|
23
|
-
- application/xml
|
24
|
-
authorization:
|
25
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
26
28
|
response: !ruby/struct:VCR::Response
|
27
29
|
status: !ruby/struct:VCR::ResponseStatus
|
28
30
|
code: 201
|
29
|
-
message: Created
|
31
|
+
message: "Created "
|
30
32
|
headers:
|
33
|
+
cache-control:
|
34
|
+
- no-cache
|
31
35
|
location:
|
32
|
-
-
|
33
|
-
|
34
|
-
-
|
36
|
+
- http://litle-test.recurly.local:3000/accounts/subscription-find-1296674173
|
37
|
+
x-runtime:
|
38
|
+
- "654"
|
35
39
|
content-type:
|
36
40
|
- application/xml; charset=utf-8
|
37
|
-
x-runtime:
|
38
|
-
- "343"
|
39
|
-
date:
|
40
|
-
- Sat, 08 Jan 2011 08:05:22 GMT
|
41
|
-
server:
|
42
|
-
- nginx/0.8.53
|
43
41
|
content-length:
|
44
42
|
- "589"
|
43
|
+
server:
|
44
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
45
|
+
date:
|
46
|
+
- Thu, 03 Feb 2011 22:21:09 GMT
|
47
|
+
connection:
|
48
|
+
- close
|
45
49
|
set-cookie:
|
46
|
-
- account_credentials=
|
50
|
+
- account_credentials=1ed644add234ec0c929ac7016511e1c0c92e709945cc4748158762995e7db2711668dc720b144907074265e82e15723d83e4f414320590c098665ba254029315%3A%3A; domain=.recurly.local; path=/
|
47
51
|
- ""
|
48
|
-
- _recurly_session=
|
49
|
-
cache-control:
|
50
|
-
- no-cache
|
52
|
+
- _recurly_session=839f459b9163ca285bdd42fb48098300; domain=.recurly.local; path=/; HttpOnly
|
51
53
|
body: |
|
52
54
|
<?xml version="1.0" encoding="UTF-8"?>
|
53
55
|
<account>
|
54
|
-
<id>subscription-find-
|
55
|
-
<account_code>subscription-find-
|
56
|
+
<id>subscription-find-1296674173</id>
|
57
|
+
<account_code>subscription-find-1296674173</account_code>
|
56
58
|
<username></username>
|
57
59
|
<email>verena@test.com</email>
|
58
60
|
<first_name>Verena</first_name>
|
@@ -60,8 +62,8 @@
|
|
60
62
|
<company_name>Recurly Ruby Gem</company_name>
|
61
63
|
<balance_in_cents type="integer">0</balance_in_cents>
|
62
64
|
<closed type="boolean">false</closed>
|
63
|
-
<hosted_login_token>
|
64
|
-
<created_at type="datetime">2011-
|
65
|
+
<hosted_login_token>2241725315f5413abbf3993d8ad81752</hosted_login_token>
|
66
|
+
<created_at type="datetime">2011-02-03T22:21:09Z</created_at>
|
65
67
|
<state>active</state>
|
66
68
|
</account>
|
67
69
|
|
@@ -69,40 +71,42 @@
|
|
69
71
|
- !ruby/struct:VCR::HTTPInteraction
|
70
72
|
request: !ruby/struct:VCR::Request
|
71
73
|
method: :get
|
72
|
-
uri:
|
74
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/company/plans/paid.xml
|
73
75
|
body:
|
74
76
|
headers:
|
77
|
+
authorization:
|
78
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
75
79
|
accept:
|
76
80
|
- application/xml
|
81
|
+
accept-encoding:
|
82
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
83
|
+
user-agent:
|
84
|
+
- Ruby
|
77
85
|
connection:
|
78
86
|
- close
|
79
|
-
authorization:
|
80
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
81
87
|
response: !ruby/struct:VCR::Response
|
82
88
|
status: !ruby/struct:VCR::ResponseStatus
|
83
89
|
code: 200
|
84
|
-
message: OK
|
90
|
+
message: "OK "
|
85
91
|
headers:
|
86
|
-
x-
|
87
|
-
-
|
88
|
-
etag:
|
89
|
-
- "\"47a9e8e85691ef0600a2dd39f113a21e\""
|
90
|
-
connection:
|
91
|
-
- close
|
92
|
+
x-runtime:
|
93
|
+
- "207"
|
92
94
|
content-type:
|
93
95
|
- application/xml; charset=utf-8
|
94
|
-
|
95
|
-
- "
|
96
|
-
date:
|
97
|
-
- Sat, 08 Jan 2011 08:05:23 GMT
|
98
|
-
server:
|
99
|
-
- nginx/0.8.53
|
100
|
-
content-length:
|
101
|
-
- "1564"
|
102
|
-
set-cookie:
|
103
|
-
- _recurly_session=6dadd385fdcc5d2ab75a97e1405108f9; domain=.recurly.com; path=/; secure; HttpOnly
|
96
|
+
etag:
|
97
|
+
- "\"70b5c605373b1a4346a2d7ed46048dc4\""
|
104
98
|
cache-control:
|
105
99
|
- private, max-age=0, must-revalidate
|
100
|
+
content-length:
|
101
|
+
- "1150"
|
102
|
+
server:
|
103
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
104
|
+
date:
|
105
|
+
- Thu, 03 Feb 2011 22:21:11 GMT
|
106
|
+
connection:
|
107
|
+
- close
|
108
|
+
set-cookie:
|
109
|
+
- _recurly_session=aa8c2754d4d0a194f5bd9c8291245526; domain=.recurly.local; path=/; HttpOnly
|
106
110
|
body: |
|
107
111
|
<?xml version="1.0" encoding="UTF-8"?>
|
108
112
|
<plan>
|
@@ -111,7 +115,7 @@
|
|
111
115
|
<description></description>
|
112
116
|
<success_url></success_url>
|
113
117
|
<cancel_url></cancel_url>
|
114
|
-
<created_at type="datetime">
|
118
|
+
<created_at type="datetime">2011-02-02T21:02:59Z</created_at>
|
115
119
|
<unit_amount_in_cents type="integer">1000</unit_amount_in_cents>
|
116
120
|
<setup_fee_in_cents type="integer">0</setup_fee_in_cents>
|
117
121
|
<plan_interval_length type="integer">1</plan_interval_length>
|
@@ -126,99 +130,89 @@
|
|
126
130
|
<plan_interval_unit>months</plan_interval_unit>
|
127
131
|
<trial_interval_length type="integer">0</trial_interval_length>
|
128
132
|
<trial_interval_unit>months</trial_interval_unit>
|
129
|
-
<created_at type="datetime">
|
133
|
+
<created_at type="datetime">2011-02-02T21:02:59Z</created_at>
|
130
134
|
</latest_version>
|
131
|
-
<add_ons type="collection">
|
132
|
-
<add_on>
|
133
|
-
<add_on_code>special</add_on_code>
|
134
|
-
<default_unit_amount_in_cents>1000</default_unit_amount_in_cents>
|
135
|
-
<default_quantity>1</default_quantity>
|
136
|
-
</add_on>
|
137
|
-
<add_on>
|
138
|
-
<add_on_code>special2</add_on_code>
|
139
|
-
<default_unit_amount_in_cents>1500</default_unit_amount_in_cents>
|
140
|
-
<default_quantity>1</default_quantity>
|
141
|
-
</add_on>
|
142
|
-
</add_ons>
|
143
135
|
</plan>
|
144
136
|
|
145
137
|
http_version: "1.1"
|
146
138
|
- !ruby/struct:VCR::HTTPInteraction
|
147
139
|
request: !ruby/struct:VCR::Request
|
148
140
|
method: :post
|
149
|
-
uri:
|
141
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/accounts/subscription-find-1296674173/subscription.xml
|
150
142
|
body: |
|
151
143
|
<?xml version="1.0" encoding="UTF-8"?>
|
152
144
|
<subscription>
|
153
|
-
<quantity type="integer">1</quantity>
|
154
145
|
<plan-code>paid</plan-code>
|
146
|
+
<quantity type="integer">1</quantity>
|
155
147
|
<account>
|
156
|
-
<
|
157
|
-
<
|
158
|
-
<company-name>Recurly Ruby Gem</company-name>
|
159
|
-
<account-code>subscription-find-1287455769</account-code>
|
160
|
-
<closed type="boolean">false</closed>
|
161
|
-
<username type="yaml" nil="true"></username>
|
162
|
-
<id>subscription-find-1287455769</id>
|
148
|
+
<account-code>subscription-find-1296674173</account-code>
|
149
|
+
<first-name>Verena</first-name>
|
163
150
|
<last-name>Test</last-name>
|
151
|
+
<email>verena@test.com</email>
|
152
|
+
<company-name>Recurly Ruby Gem</company-name>
|
164
153
|
<accept-language type="yaml" nil="true"></accept-language>
|
154
|
+
<id>subscription-find-1296674173</id>
|
155
|
+
<username type="yaml" nil="true"></username>
|
156
|
+
<balance-in-cents type="integer">0</balance-in-cents>
|
157
|
+
<closed type="boolean">false</closed>
|
158
|
+
<hosted-login-token>2241725315f5413abbf3993d8ad81752</hosted-login-token>
|
159
|
+
<created-at type="datetime">2011-02-03T22:21:09Z</created-at>
|
160
|
+
<state>active</state>
|
165
161
|
<billing-info>
|
166
162
|
<address1>123 Test St</address1>
|
167
163
|
<city>San Francisco</city>
|
164
|
+
<state>CA</state>
|
168
165
|
<zip>94115</zip>
|
169
166
|
<country>US</country>
|
170
167
|
<credit-card>
|
171
|
-
<number>
|
172
|
-
<month type="integer">1</month>
|
168
|
+
<number>4111111111111111</number>
|
173
169
|
<year type="integer">2012</year>
|
170
|
+
<month type="integer">2</month>
|
174
171
|
<verification-value>123</verification-value>
|
175
172
|
</credit-card>
|
176
|
-
<last-name>Test</last-name>
|
177
173
|
<first-name>Verena</first-name>
|
178
|
-
<
|
174
|
+
<last-name>Test</last-name>
|
179
175
|
</billing-info>
|
180
|
-
<balance-in-cents type="integer">0</balance-in-cents>
|
181
|
-
<state>active</state>
|
182
|
-
<email>verena@test.com</email>
|
183
|
-
<first-name>Verena</first-name>
|
184
176
|
</account>
|
185
177
|
</subscription>
|
186
178
|
|
187
179
|
headers:
|
180
|
+
authorization:
|
181
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
182
|
+
content-type:
|
183
|
+
- application/xml
|
188
184
|
accept:
|
189
185
|
- "*/*"
|
186
|
+
user-agent:
|
187
|
+
- Ruby
|
190
188
|
connection:
|
191
189
|
- close
|
192
|
-
content-type:
|
193
|
-
- application/xml
|
194
|
-
authorization:
|
195
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
196
190
|
response: !ruby/struct:VCR::Response
|
197
191
|
status: !ruby/struct:VCR::ResponseStatus
|
198
192
|
code: 201
|
199
|
-
message: Created
|
193
|
+
message: "Created "
|
200
194
|
headers:
|
201
|
-
|
202
|
-
-
|
195
|
+
cache-control:
|
196
|
+
- no-cache
|
197
|
+
x-runtime:
|
198
|
+
- "4320"
|
203
199
|
content-type:
|
204
200
|
- application/xml; charset=utf-8
|
205
|
-
x-runtime:
|
206
|
-
- "465"
|
207
|
-
date:
|
208
|
-
- Sat, 08 Jan 2011 08:05:25 GMT
|
209
|
-
server:
|
210
|
-
- nginx/0.8.53
|
211
201
|
content-length:
|
212
202
|
- "904"
|
203
|
+
server:
|
204
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
205
|
+
date:
|
206
|
+
- Thu, 03 Feb 2011 22:21:17 GMT
|
207
|
+
connection:
|
208
|
+
- close
|
213
209
|
set-cookie:
|
214
|
-
- _recurly_session=
|
215
|
-
cache-control:
|
216
|
-
- no-cache
|
210
|
+
- _recurly_session=333314c1d174a6e3c8f48fb77d7e9355; domain=.recurly.local; path=/; HttpOnly
|
217
211
|
body: |
|
218
212
|
<?xml version="1.0" encoding="UTF-8"?>
|
219
213
|
<subscription>
|
220
|
-
<id>subscription-find-
|
221
|
-
<account_code>subscription-find-
|
214
|
+
<id>subscription-find-1296674173</id>
|
215
|
+
<account_code>subscription-find-1296674173</account_code>
|
222
216
|
<plan>
|
223
217
|
<plan_code>paid</plan_code>
|
224
218
|
<name>Paid</name>
|
@@ -226,11 +220,11 @@
|
|
226
220
|
<state>active</state>
|
227
221
|
<quantity type="integer">1</quantity>
|
228
222
|
<total_amount_in_cents type="integer">1000</total_amount_in_cents>
|
229
|
-
<activated_at type="datetime">2011-
|
223
|
+
<activated_at type="datetime">2011-02-03T22:21:13Z</activated_at>
|
230
224
|
<canceled_at nil="true" type="datetime"></canceled_at>
|
231
225
|
<expires_at nil="true" type="datetime"></expires_at>
|
232
|
-
<current_period_started_at type="datetime">2011-
|
233
|
-
<current_period_ends_at type="datetime">2011-
|
226
|
+
<current_period_started_at type="datetime">2011-02-03T22:21:13Z</current_period_started_at>
|
227
|
+
<current_period_ends_at type="datetime">2011-03-03T22:21:13Z</current_period_ends_at>
|
234
228
|
<trial_started_at nil="true" type="datetime"></trial_started_at>
|
235
229
|
<trial_ends_at nil="true" type="datetime"></trial_ends_at>
|
236
230
|
<add_ons type="array">
|
@@ -241,45 +235,47 @@
|
|
241
235
|
- !ruby/struct:VCR::HTTPInteraction
|
242
236
|
request: !ruby/struct:VCR::Request
|
243
237
|
method: :get
|
244
|
-
uri:
|
238
|
+
uri: http://isaac%40recurly.com:isaac1024@litle-test.recurly.local:3000/accounts/subscription-find-1296674173/subscription.xml
|
245
239
|
body:
|
246
240
|
headers:
|
241
|
+
authorization:
|
242
|
+
- Basic aXNhYWNAcmVjdXJseS5jb206aXNhYWMxMDI0
|
247
243
|
accept:
|
248
244
|
- application/xml
|
245
|
+
accept-encoding:
|
246
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
247
|
+
user-agent:
|
248
|
+
- Ruby
|
249
249
|
connection:
|
250
250
|
- close
|
251
|
-
authorization:
|
252
|
-
- Basic cmFpbHNqZWRpQHNvZ2V0dGhpcy5jb206N1BDQjJtWkM=
|
253
251
|
response: !ruby/struct:VCR::Response
|
254
252
|
status: !ruby/struct:VCR::ResponseStatus
|
255
253
|
code: 200
|
256
|
-
message: OK
|
254
|
+
message: "OK "
|
257
255
|
headers:
|
258
|
-
x-
|
259
|
-
-
|
260
|
-
etag:
|
261
|
-
- "\"583cc969dc60b92c716228e0daf01293\""
|
262
|
-
connection:
|
263
|
-
- close
|
256
|
+
x-runtime:
|
257
|
+
- "248"
|
264
258
|
content-type:
|
265
259
|
- application/xml; charset=utf-8
|
266
|
-
|
267
|
-
- "
|
268
|
-
|
269
|
-
-
|
270
|
-
server:
|
271
|
-
- nginx/0.8.53
|
260
|
+
etag:
|
261
|
+
- "\"620ca7af70a86ac2e66fc9ca7eaa9d0d\""
|
262
|
+
cache-control:
|
263
|
+
- private, max-age=0, must-revalidate
|
272
264
|
content-length:
|
273
265
|
- "904"
|
266
|
+
server:
|
267
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
268
|
+
date:
|
269
|
+
- Thu, 03 Feb 2011 22:21:19 GMT
|
270
|
+
connection:
|
271
|
+
- close
|
274
272
|
set-cookie:
|
275
|
-
- _recurly_session=
|
276
|
-
cache-control:
|
277
|
-
- private, max-age=0, must-revalidate
|
273
|
+
- _recurly_session=1baae3237b02aad2fbe58c9ac1938b3d; domain=.recurly.local; path=/; HttpOnly
|
278
274
|
body: |
|
279
275
|
<?xml version="1.0" encoding="UTF-8"?>
|
280
276
|
<subscription>
|
281
|
-
<id>subscription-find-
|
282
|
-
<account_code>subscription-find-
|
277
|
+
<id>subscription-find-1296674173</id>
|
278
|
+
<account_code>subscription-find-1296674173</account_code>
|
283
279
|
<plan>
|
284
280
|
<plan_code>paid</plan_code>
|
285
281
|
<name>Paid</name>
|
@@ -287,11 +283,11 @@
|
|
287
283
|
<state>active</state>
|
288
284
|
<quantity type="integer">1</quantity>
|
289
285
|
<total_amount_in_cents type="integer">1000</total_amount_in_cents>
|
290
|
-
<activated_at type="datetime">2011-
|
286
|
+
<activated_at type="datetime">2011-02-03T22:21:13Z</activated_at>
|
291
287
|
<canceled_at nil="true" type="datetime"></canceled_at>
|
292
288
|
<expires_at nil="true" type="datetime"></expires_at>
|
293
|
-
<current_period_started_at type="datetime">2011-
|
294
|
-
<current_period_ends_at type="datetime">2011-
|
289
|
+
<current_period_started_at type="datetime">2011-02-03T22:21:13Z</current_period_started_at>
|
290
|
+
<current_period_ends_at type="datetime">2011-03-03T22:21:13Z</current_period_ends_at>
|
295
291
|
<trial_started_at nil="true" type="datetime"></trial_started_at>
|
296
292
|
<trial_ends_at nil="true" type="datetime"></trial_ends_at>
|
297
293
|
<add_ons type="array">
|