recurly 0.3.3 → 0.3.4
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/README.md +15 -11
- data/lib/patches/active_resource/connection.rb +10 -0
- data/lib/recurly.rb +35 -9
- data/lib/recurly/account.rb +22 -1
- data/lib/recurly/account_base.rb +35 -0
- data/lib/recurly/base.rb +26 -39
- data/lib/recurly/billing_info.rb +40 -1
- data/lib/recurly/charge.rb +12 -1
- data/lib/recurly/coupon.rb +8 -0
- data/lib/recurly/credit.rb +12 -1
- data/lib/recurly/exceptions.rb +19 -0
- data/lib/recurly/invoice.rb +1 -1
- data/lib/recurly/plan.rb +13 -1
- data/lib/recurly/rails3/recurly.rake +5 -3
- data/lib/recurly/subscription.rb +21 -3
- data/lib/recurly/transaction.rb +29 -1
- data/lib/recurly/transparent.rb +140 -0
- data/lib/recurly/version.rb +1 -1
- data/spec/config/recurly.yml +12 -0
- data/spec/config/test1.yml +3 -1
- data/spec/config/test2.yml +4 -2
- data/spec/integration/credit_spec.rb +6 -6
- data/spec/integration/plan_spec.rb +2 -2
- data/spec/support/factory.rb +5 -3
- data/spec/unit/account_spec.rb +19 -0
- data/spec/unit/billing_info_spec.rb +38 -0
- data/spec/unit/charge_spec.rb +18 -0
- data/spec/unit/config_spec.rb +10 -6
- data/spec/unit/coupon_spec.rb +13 -0
- data/spec/unit/credit_spec.rb +18 -0
- data/spec/unit/plan_spec.rb +18 -0
- data/spec/unit/subscription_spec.rb +25 -0
- data/spec/unit/transaction_spec.rb +32 -0
- data/spec/unit/transparent_spec.rb +114 -0
- data/spec/vcr/account/accept-language-account/{1296674173.yml → 1297746103.yml} +16 -13
- data/spec/vcr/account/close/{1296674173.yml → 1297746103.yml} +31 -28
- data/spec/vcr/account/create-blank/{1296674173.yml → 1297746103.yml} +9 -5
- data/spec/vcr/account/create-duplicate/{1296674173.yml → 1297746103.yml} +22 -15
- data/spec/vcr/account/create-min/{1296674173.yml → 1297746103.yml} +16 -13
- data/spec/vcr/account/create/{1296674173.yml → 1297746103.yml} +16 -13
- data/spec/vcr/account/find/{1296674173.yml → 1297746103.yml} +29 -26
- data/spec/vcr/account/list/1297746103.yml +1579 -0
- data/spec/vcr/account/update/{1296674173.yml → 1297746103.yml} +54 -47
- data/spec/vcr/billing/create/{1296690812.yml → 1298594128.yml} +37 -34
- data/spec/vcr/billing/destroy/{1296690812.yml → 1298594128.yml} +46 -43
- data/spec/vcr/billing/find/{1296690812.yml → 1298594128.yml} +47 -44
- data/spec/vcr/billing/update/{1296690812.yml → 1298594128.yml} +50 -47
- data/spec/vcr/charge/create/{1296674173.yml → 1297746103.yml} +48 -45
- data/spec/vcr/charge/delete-uninvoiced/{1296674173.yml → 1297746103.yml} +49 -46
- data/spec/vcr/charge/list-all/{1296674173.yml → 1297746103.yml} +61 -58
- data/spec/vcr/charge/list-invoiced/{1296674173.yml → 1297746103.yml} +92 -89
- data/spec/vcr/charge/list-pending/{1296674173.yml → 1297746103.yml} +61 -58
- data/spec/vcr/charge/lookup/{1296674173.yml → 1297746103.yml} +34 -31
- data/spec/vcr/coupon/create/{1296774903.yml → 1299714521.yml} +35 -32
- data/spec/vcr/coupon/destroy/{1296688818.yml → 1299714521.yml} +34 -31
- data/spec/vcr/{coupon/create/1296688818.yml → credit/create/1299714599.yml} +53 -53
- data/spec/vcr/credit/delete/1299714599.yml +262 -0
- data/spec/vcr/credit/list/1299714599.yml +319 -0
- data/spec/vcr/credit/lookup/1299714599.yml +183 -0
- data/spec/vcr/invoice/create-no-charges/{1296674173.yml → 1297746103.yml} +34 -31
- data/spec/vcr/invoice/create/{1296674173.yml → 1297746103.yml} +63 -60
- data/spec/vcr/invoice/list/{1296674173.yml → 1297746103.yml} +87 -84
- data/spec/vcr/invoice/lookup/{1296674173.yml → 1297746103.yml} +64 -61
- data/spec/vcr/plan/all.yml +30 -30
- data/spec/vcr/plan/find.yml +25 -25
- data/spec/vcr/plan/update.yml +16 -15
- data/spec/vcr/subscription/addons/add/{1296674173.yml → 1297746103.yml} +44 -40
- data/spec/vcr/subscription/addons/create/{1296674173.yml → 1297746103.yml} +44 -40
- data/spec/vcr/subscription/addons/remove/{1296674173.yml → 1297746103.yml} +44 -40
- data/spec/vcr/subscription/cancel-with-code/{1296674173.yml → 1297746103.yml} +99 -95
- data/spec/vcr/subscription/cancel/{1296674173.yml → 1297746103.yml} +86 -82
- data/spec/vcr/subscription/change1/{1296674173.yml → 1297746103.yml} +82 -78
- data/spec/vcr/subscription/change2/{1296674173.yml → 1297746103.yml} +82 -78
- data/spec/vcr/subscription/create/{1296674173.yml → 1297746103.yml} +49 -45
- data/spec/vcr/subscription/find/{1296674173.yml → 1297746103.yml} +60 -56
- data/spec/vcr/subscription/reactivate/{1296674173.yml → 1297746103.yml} +93 -89
- data/spec/vcr/subscription/refund-full/{1296674173.yml → 1297746103.yml} +77 -73
- data/spec/vcr/subscription/refund-none/{1296674173.yml → 1297746103.yml} +77 -73
- data/spec/vcr/subscription/refund-partial/{1296674173.yml → 1297746103.yml} +77 -73
- data/spec/vcr/transaction/all/{1296674173.yml → 1297746103.yml} +107 -107
- data/spec/vcr/transaction/create-no-account/{1296674173.yml → 1297746103.yml} +14 -13
- data/spec/vcr/transaction/create-with-account/{1296674173.yml → 1297746103.yml} +46 -58
- data/spec/vcr/transaction/list-filled/1297746103.yml +213 -0
- data/spec/vcr/transaction/list-initial/{1296674173.yml → 1297746103.yml} +38 -35
- data/spec/vcr/transaction/lookup/1297746103.yml +213 -0
- data/spec/vcr/transaction/refund/1297746103.yml +213 -0
- data/spec/vcr/transaction/void/1297746103.yml +213 -0
- metadata +146 -139
- data/spec/vcr/account/list/1296674173.yml +0 -55
- data/spec/vcr/coupon/destroy/1296774903.yml +0 -207
- data/spec/vcr/credit/create/1296674173.yml +0 -121
- data/spec/vcr/credit/delete/1296674173.yml +0 -121
- data/spec/vcr/credit/list/1296674173.yml +0 -121
- data/spec/vcr/credit/lookup/1296674173.yml +0 -121
- data/spec/vcr/plan/delete/1296674173.yml +0 -225
- data/spec/vcr/transaction/list-filled/1296674173.yml +0 -487
- data/spec/vcr/transaction/lookup/1296674173.yml +0 -563
- data/spec/vcr/transaction/refund/1296674173.yml +0 -287
- data/spec/vcr/transaction/void/1296674173.yml +0 -352
@@ -0,0 +1,183 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts.xml
|
6
|
+
body: |
|
7
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
8
|
+
<account>
|
9
|
+
<account-code>credit-lookup-1299714599</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 YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
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/credit-lookup-1299714599
|
41
|
+
x-runtime:
|
42
|
+
- "570"
|
43
|
+
content-type:
|
44
|
+
- application/xml; charset=utf-8
|
45
|
+
content-length:
|
46
|
+
- "581"
|
47
|
+
server:
|
48
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
49
|
+
date:
|
50
|
+
- Fri, 11 Mar 2011 18:50:15 GMT
|
51
|
+
connection:
|
52
|
+
- close
|
53
|
+
set-cookie:
|
54
|
+
- account_credentials=22fe71f091c12892cf6379e75c25f5ad358be97e5b599c793582cc9fcd2a7c5a184bac74bba24ea8ba0142066ab626a79d7c2ea0fce9ba36e4284b3b74594db3%3A%3A; domain=.recurly.local; path=/
|
55
|
+
- _recurly_session=497f3ef2dde85dcb02fd91337441235f; domain=.recurly.local; path=/; HttpOnly
|
56
|
+
body: |
|
57
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
58
|
+
<account>
|
59
|
+
<id>credit-lookup-1299714599</id>
|
60
|
+
<account_code>credit-lookup-1299714599</account_code>
|
61
|
+
<username></username>
|
62
|
+
<email>verena@test.com</email>
|
63
|
+
<first_name>Verena</first_name>
|
64
|
+
<last_name>Test</last_name>
|
65
|
+
<company_name>Recurly Ruby Gem</company_name>
|
66
|
+
<balance_in_cents type="integer">0</balance_in_cents>
|
67
|
+
<closed type="boolean">false</closed>
|
68
|
+
<hosted_login_token>fa18cfe4d40a4efeb0da03dd79c04361</hosted_login_token>
|
69
|
+
<created_at type="datetime">2011-03-11T18:50:15Z</created_at>
|
70
|
+
<state>active</state>
|
71
|
+
</account>
|
72
|
+
|
73
|
+
http_version: "1.1"
|
74
|
+
- !ruby/struct:VCR::HTTPInteraction
|
75
|
+
request: !ruby/struct:VCR::Request
|
76
|
+
method: :post
|
77
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/credit-lookup-1299714599/credits.xml
|
78
|
+
body: |
|
79
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
80
|
+
<credit>
|
81
|
+
<amount-in-cents type="integer">1315</amount-in-cents>
|
82
|
+
<description>free moniez 4 u</description>
|
83
|
+
</credit>
|
84
|
+
|
85
|
+
headers:
|
86
|
+
authorization:
|
87
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
88
|
+
content-type:
|
89
|
+
- application/xml
|
90
|
+
accept:
|
91
|
+
- "*/*"
|
92
|
+
user-agent:
|
93
|
+
- Ruby
|
94
|
+
connection:
|
95
|
+
- close
|
96
|
+
response: !ruby/struct:VCR::Response
|
97
|
+
status: !ruby/struct:VCR::ResponseStatus
|
98
|
+
code: 201
|
99
|
+
message: "Created "
|
100
|
+
headers:
|
101
|
+
cache-control:
|
102
|
+
- no-cache
|
103
|
+
x-runtime:
|
104
|
+
- "223"
|
105
|
+
content-type:
|
106
|
+
- application/xml; charset=utf-8
|
107
|
+
content-length:
|
108
|
+
- "516"
|
109
|
+
server:
|
110
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
111
|
+
date:
|
112
|
+
- Fri, 11 Mar 2011 18:50:17 GMT
|
113
|
+
connection:
|
114
|
+
- close
|
115
|
+
set-cookie:
|
116
|
+
- _recurly_session=0b46fcf860d9e41f9f46ab558797b38c; domain=.recurly.local; path=/; HttpOnly
|
117
|
+
body: |
|
118
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
119
|
+
<credit type="credit">
|
120
|
+
<id>0bca01a675a34f779c50155b80db952f</id>
|
121
|
+
<account_code>credit-lookup-1299714599</account_code>
|
122
|
+
<amount_in_cents type="integer">-1315</amount_in_cents>
|
123
|
+
<start_date type="datetime">2011-03-11T18:50:17Z</start_date>
|
124
|
+
<end_date nil="true" type="datetime"></end_date>
|
125
|
+
<invoice_number nil="true" type="integer"></invoice_number>
|
126
|
+
<description>free moniez 4 u</description>
|
127
|
+
<created_at type="datetime">2011-03-11T18:50:17Z</created_at>
|
128
|
+
</credit>
|
129
|
+
|
130
|
+
http_version: "1.1"
|
131
|
+
- !ruby/struct:VCR::HTTPInteraction
|
132
|
+
request: !ruby/struct:VCR::Request
|
133
|
+
method: :get
|
134
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/credit-lookup-1299714599/credits/0bca01a675a34f779c50155b80db952f.xml
|
135
|
+
body:
|
136
|
+
headers:
|
137
|
+
authorization:
|
138
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
139
|
+
accept:
|
140
|
+
- application/xml
|
141
|
+
accept-encoding:
|
142
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
143
|
+
user-agent:
|
144
|
+
- Ruby
|
145
|
+
connection:
|
146
|
+
- close
|
147
|
+
response: !ruby/struct:VCR::Response
|
148
|
+
status: !ruby/struct:VCR::ResponseStatus
|
149
|
+
code: 200
|
150
|
+
message: "OK "
|
151
|
+
headers:
|
152
|
+
x-runtime:
|
153
|
+
- "199"
|
154
|
+
content-type:
|
155
|
+
- application/xml; charset=utf-8
|
156
|
+
etag:
|
157
|
+
- "\"d64d0a8760d29e86ff14722726d946c9\""
|
158
|
+
cache-control:
|
159
|
+
- private, max-age=0, must-revalidate
|
160
|
+
content-length:
|
161
|
+
- "516"
|
162
|
+
server:
|
163
|
+
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
164
|
+
date:
|
165
|
+
- Fri, 11 Mar 2011 18:50:19 GMT
|
166
|
+
connection:
|
167
|
+
- close
|
168
|
+
set-cookie:
|
169
|
+
- _recurly_session=89a729c62c3edc4c05799cf5dead21ac; domain=.recurly.local; path=/; HttpOnly
|
170
|
+
body: |
|
171
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
172
|
+
<credit type="credit">
|
173
|
+
<id>0bca01a675a34f779c50155b80db952f</id>
|
174
|
+
<account_code>credit-lookup-1299714599</account_code>
|
175
|
+
<amount_in_cents type="integer">-1315</amount_in_cents>
|
176
|
+
<start_date type="datetime">2011-03-11T18:50:17Z</start_date>
|
177
|
+
<end_date nil="true" type="datetime"></end_date>
|
178
|
+
<invoice_number nil="true" type="integer"></invoice_number>
|
179
|
+
<description>free moniez 4 u</description>
|
180
|
+
<created_at type="datetime">2011-03-11T18:50:17Z</created_at>
|
181
|
+
</credit>
|
182
|
+
|
183
|
+
http_version: "1.1"
|
@@ -2,21 +2,25 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri: http://
|
5
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts.xml
|
6
6
|
body: |
|
7
7
|
<?xml version="1.0" encoding="UTF-8"?>
|
8
8
|
<account>
|
9
|
-
<account-code>invoice-create-no-charges-
|
9
|
+
<account-code>invoice-create-no-charges-1297746103</account-code>
|
10
10
|
<first-name>Verena</first-name>
|
11
11
|
<last-name>Test</last-name>
|
12
12
|
<email>verena@test.com</email>
|
13
13
|
<company-name>Recurly Ruby Gem</company-name>
|
14
|
+
<billing-info>
|
15
|
+
<credit-card>
|
16
|
+
</credit-card>
|
17
|
+
</billing-info>
|
14
18
|
<accept-language type="yaml" nil="true"></accept-language>
|
15
19
|
</account>
|
16
20
|
|
17
21
|
headers:
|
18
22
|
authorization:
|
19
|
-
- Basic
|
23
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
20
24
|
content-type:
|
21
25
|
- application/xml
|
22
26
|
accept:
|
@@ -33,9 +37,9 @@
|
|
33
37
|
cache-control:
|
34
38
|
- no-cache
|
35
39
|
location:
|
36
|
-
- http://
|
40
|
+
- http://app.recurly.local:3000/accounts/invoice-create-no-charges-1297746103
|
37
41
|
x-runtime:
|
38
|
-
- "
|
42
|
+
- "584"
|
39
43
|
content-type:
|
40
44
|
- application/xml; charset=utf-8
|
41
45
|
content-length:
|
@@ -43,18 +47,17 @@
|
|
43
47
|
server:
|
44
48
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
45
49
|
date:
|
46
|
-
-
|
50
|
+
- Fri, 11 Mar 2011 18:50:47 GMT
|
47
51
|
connection:
|
48
52
|
- close
|
49
53
|
set-cookie:
|
50
|
-
- account_credentials=
|
51
|
-
-
|
52
|
-
- _recurly_session=cb720a4d65d1589d60dc78151587a22b; domain=.recurly.local; path=/; HttpOnly
|
54
|
+
- account_credentials=6532e5d18afa5b0d8db9fdd7243a90eb7a300e041200b536322a37ca342716deaa42f1a83bab56fe669e6c1b9071a18d56b8d82aedf5b17d71cd6d444ee7e125%3A%3A; domain=.recurly.local; path=/
|
55
|
+
- _recurly_session=9a5660c2955d7897cc0b9f81a6ff8849; domain=.recurly.local; path=/; HttpOnly
|
53
56
|
body: |
|
54
57
|
<?xml version="1.0" encoding="UTF-8"?>
|
55
58
|
<account>
|
56
|
-
<id>invoice-create-no-charges-
|
57
|
-
<account_code>invoice-create-no-charges-
|
59
|
+
<id>invoice-create-no-charges-1297746103</id>
|
60
|
+
<account_code>invoice-create-no-charges-1297746103</account_code>
|
58
61
|
<username></username>
|
59
62
|
<email>verena@test.com</email>
|
60
63
|
<first_name>Verena</first_name>
|
@@ -62,8 +65,8 @@
|
|
62
65
|
<company_name>Recurly Ruby Gem</company_name>
|
63
66
|
<balance_in_cents type="integer">0</balance_in_cents>
|
64
67
|
<closed type="boolean">false</closed>
|
65
|
-
<hosted_login_token>
|
66
|
-
<created_at type="datetime">2011-
|
68
|
+
<hosted_login_token>3b1d53b96b884eeaac47c2256b25afa4</hosted_login_token>
|
69
|
+
<created_at type="datetime">2011-03-11T18:50:47Z</created_at>
|
67
70
|
<state>active</state>
|
68
71
|
</account>
|
69
72
|
|
@@ -71,10 +74,12 @@
|
|
71
74
|
- !ruby/struct:VCR::HTTPInteraction
|
72
75
|
request: !ruby/struct:VCR::Request
|
73
76
|
method: :put
|
74
|
-
uri: http://
|
77
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/invoice-create-no-charges-1297746103/billing_info.xml
|
75
78
|
body: |
|
76
79
|
<?xml version="1.0" encoding="UTF-8"?>
|
77
80
|
<billing-info>
|
81
|
+
<first-name>Verena</first-name>
|
82
|
+
<last-name>Test</last-name>
|
78
83
|
<address1>123 Test St</address1>
|
79
84
|
<city>San Francisco</city>
|
80
85
|
<state>CA</state>
|
@@ -83,17 +88,15 @@
|
|
83
88
|
<credit-card>
|
84
89
|
<number>4111111111111111</number>
|
85
90
|
<year type="integer">2012</year>
|
86
|
-
<month type="integer">
|
91
|
+
<month type="integer">3</month>
|
87
92
|
<verification-value>123</verification-value>
|
88
93
|
</credit-card>
|
89
|
-
<account-code>invoice-create-no-charges-
|
90
|
-
<first-name>Verena</first-name>
|
91
|
-
<last-name>Test</last-name>
|
94
|
+
<account-code>invoice-create-no-charges-1297746103</account-code>
|
92
95
|
</billing-info>
|
93
96
|
|
94
97
|
headers:
|
95
98
|
authorization:
|
96
|
-
- Basic
|
99
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
97
100
|
content-type:
|
98
101
|
- application/xml
|
99
102
|
accept:
|
@@ -108,11 +111,11 @@
|
|
108
111
|
message: "OK "
|
109
112
|
headers:
|
110
113
|
x-runtime:
|
111
|
-
- "
|
114
|
+
- "1842"
|
112
115
|
content-type:
|
113
116
|
- application/xml; charset=utf-8
|
114
117
|
etag:
|
115
|
-
- "\"
|
118
|
+
- "\"6ffcd26c84c0d119dabba77ea8e090eb\""
|
116
119
|
cache-control:
|
117
120
|
- private, max-age=0, must-revalidate
|
118
121
|
content-length:
|
@@ -120,15 +123,15 @@
|
|
120
123
|
server:
|
121
124
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
122
125
|
date:
|
123
|
-
-
|
126
|
+
- Fri, 11 Mar 2011 18:50:51 GMT
|
124
127
|
connection:
|
125
128
|
- close
|
126
129
|
set-cookie:
|
127
|
-
- _recurly_session=
|
130
|
+
- _recurly_session=2987a67198ef3e0284063f9fb8596862; domain=.recurly.local; path=/; HttpOnly
|
128
131
|
body: |
|
129
132
|
<?xml version="1.0" encoding="UTF-8"?>
|
130
133
|
<billing_info>
|
131
|
-
<account_code>invoice-create-no-charges-
|
134
|
+
<account_code>invoice-create-no-charges-1297746103</account_code>
|
132
135
|
<first_name>Verena</first_name>
|
133
136
|
<last_name>Test</last_name>
|
134
137
|
<address1>123 Test St</address1>
|
@@ -143,17 +146,17 @@
|
|
143
146
|
<credit_card>
|
144
147
|
<type>visa</type>
|
145
148
|
<last_four>1111</last_four>
|
146
|
-
<month type="integer">
|
149
|
+
<month type="integer">3</month>
|
147
150
|
<year type="integer">2012</year>
|
148
151
|
</credit_card>
|
149
|
-
<updated_at type="datetime">2011-
|
152
|
+
<updated_at type="datetime">2011-03-11T18:50:51Z</updated_at>
|
150
153
|
</billing_info>
|
151
154
|
|
152
155
|
http_version: "1.1"
|
153
156
|
- !ruby/struct:VCR::HTTPInteraction
|
154
157
|
request: !ruby/struct:VCR::Request
|
155
158
|
method: :post
|
156
|
-
uri: http://
|
159
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/invoice-create-no-charges-1297746103/invoices.xml
|
157
160
|
body: |
|
158
161
|
<?xml version="1.0" encoding="UTF-8"?>
|
159
162
|
<invoice>
|
@@ -161,7 +164,7 @@
|
|
161
164
|
|
162
165
|
headers:
|
163
166
|
authorization:
|
164
|
-
- Basic
|
167
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
165
168
|
content-type:
|
166
169
|
- application/xml
|
167
170
|
accept:
|
@@ -178,7 +181,7 @@
|
|
178
181
|
cache-control:
|
179
182
|
- no-cache
|
180
183
|
x-runtime:
|
181
|
-
- "
|
184
|
+
- "193"
|
182
185
|
content-type:
|
183
186
|
- application/xml; charset=utf-8
|
184
187
|
content-length:
|
@@ -186,11 +189,11 @@
|
|
186
189
|
server:
|
187
190
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
188
191
|
date:
|
189
|
-
-
|
192
|
+
- Fri, 11 Mar 2011 18:50:54 GMT
|
190
193
|
connection:
|
191
194
|
- close
|
192
195
|
set-cookie:
|
193
|
-
- _recurly_session=
|
196
|
+
- _recurly_session=b0367c21cafebd33a50a6bd5a663e9a0; domain=.recurly.local; path=/; HttpOnly
|
194
197
|
body: |
|
195
198
|
<?xml version="1.0" encoding="UTF-8"?>
|
196
199
|
<errors>
|
@@ -2,21 +2,25 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri: http://
|
5
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts.xml
|
6
6
|
body: |
|
7
7
|
<?xml version="1.0" encoding="UTF-8"?>
|
8
8
|
<account>
|
9
|
-
<account-code>invoice-create-
|
9
|
+
<account-code>invoice-create-1297746103</account-code>
|
10
10
|
<first-name>Verena</first-name>
|
11
11
|
<last-name>Test</last-name>
|
12
12
|
<email>verena@test.com</email>
|
13
13
|
<company-name>Recurly Ruby Gem</company-name>
|
14
|
+
<billing-info>
|
15
|
+
<credit-card>
|
16
|
+
</credit-card>
|
17
|
+
</billing-info>
|
14
18
|
<accept-language type="yaml" nil="true"></accept-language>
|
15
19
|
</account>
|
16
20
|
|
17
21
|
headers:
|
18
22
|
authorization:
|
19
|
-
- Basic
|
23
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
20
24
|
content-type:
|
21
25
|
- application/xml
|
22
26
|
accept:
|
@@ -33,9 +37,9 @@
|
|
33
37
|
cache-control:
|
34
38
|
- no-cache
|
35
39
|
location:
|
36
|
-
- http://
|
40
|
+
- http://app.recurly.local:3000/accounts/invoice-create-1297746103
|
37
41
|
x-runtime:
|
38
|
-
- "
|
42
|
+
- "571"
|
39
43
|
content-type:
|
40
44
|
- application/xml; charset=utf-8
|
41
45
|
content-length:
|
@@ -43,18 +47,17 @@
|
|
43
47
|
server:
|
44
48
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
45
49
|
date:
|
46
|
-
-
|
50
|
+
- Fri, 11 Mar 2011 18:50:33 GMT
|
47
51
|
connection:
|
48
52
|
- close
|
49
53
|
set-cookie:
|
50
|
-
- account_credentials=
|
51
|
-
-
|
52
|
-
- _recurly_session=6a39a2297bacc140dba27348b11b1ee0; domain=.recurly.local; path=/; HttpOnly
|
54
|
+
- account_credentials=221fd9945fb1540d826eb17cbd8efaff74034ce0eab0791bac4282f0886574cb88a8a0930e8a97921513a751644ae574d2a24fadf75c8c72b897789874d75f12%3A%3A; domain=.recurly.local; path=/
|
55
|
+
- _recurly_session=e273ac85c9a0c59f6dfb7625c4c318a6; domain=.recurly.local; path=/; HttpOnly
|
53
56
|
body: |
|
54
57
|
<?xml version="1.0" encoding="UTF-8"?>
|
55
58
|
<account>
|
56
|
-
<id>invoice-create-
|
57
|
-
<account_code>invoice-create-
|
59
|
+
<id>invoice-create-1297746103</id>
|
60
|
+
<account_code>invoice-create-1297746103</account_code>
|
58
61
|
<username></username>
|
59
62
|
<email>verena@test.com</email>
|
60
63
|
<first_name>Verena</first_name>
|
@@ -62,8 +65,8 @@
|
|
62
65
|
<company_name>Recurly Ruby Gem</company_name>
|
63
66
|
<balance_in_cents type="integer">0</balance_in_cents>
|
64
67
|
<closed type="boolean">false</closed>
|
65
|
-
<hosted_login_token>
|
66
|
-
<created_at type="datetime">2011-
|
68
|
+
<hosted_login_token>eb41534ce6014c8f9690eb3ab1ddfcc9</hosted_login_token>
|
69
|
+
<created_at type="datetime">2011-03-11T18:50:33Z</created_at>
|
67
70
|
<state>active</state>
|
68
71
|
</account>
|
69
72
|
|
@@ -71,10 +74,12 @@
|
|
71
74
|
- !ruby/struct:VCR::HTTPInteraction
|
72
75
|
request: !ruby/struct:VCR::Request
|
73
76
|
method: :put
|
74
|
-
uri: http://
|
77
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/invoice-create-1297746103/billing_info.xml
|
75
78
|
body: |
|
76
79
|
<?xml version="1.0" encoding="UTF-8"?>
|
77
80
|
<billing-info>
|
81
|
+
<first-name>Verena</first-name>
|
82
|
+
<last-name>Test</last-name>
|
78
83
|
<address1>123 Test St</address1>
|
79
84
|
<city>San Francisco</city>
|
80
85
|
<state>CA</state>
|
@@ -83,17 +88,15 @@
|
|
83
88
|
<credit-card>
|
84
89
|
<number>4111111111111111</number>
|
85
90
|
<year type="integer">2012</year>
|
86
|
-
<month type="integer">
|
91
|
+
<month type="integer">3</month>
|
87
92
|
<verification-value>123</verification-value>
|
88
93
|
</credit-card>
|
89
|
-
<account-code>invoice-create-
|
90
|
-
<first-name>Verena</first-name>
|
91
|
-
<last-name>Test</last-name>
|
94
|
+
<account-code>invoice-create-1297746103</account-code>
|
92
95
|
</billing-info>
|
93
96
|
|
94
97
|
headers:
|
95
98
|
authorization:
|
96
|
-
- Basic
|
99
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
97
100
|
content-type:
|
98
101
|
- application/xml
|
99
102
|
accept:
|
@@ -108,11 +111,11 @@
|
|
108
111
|
message: "OK "
|
109
112
|
headers:
|
110
113
|
x-runtime:
|
111
|
-
- "
|
114
|
+
- "1608"
|
112
115
|
content-type:
|
113
116
|
- application/xml; charset=utf-8
|
114
117
|
etag:
|
115
|
-
- "\"
|
118
|
+
- "\"9fd2b0035afb6a86834033476c7fb662\""
|
116
119
|
cache-control:
|
117
120
|
- private, max-age=0, must-revalidate
|
118
121
|
content-length:
|
@@ -120,15 +123,15 @@
|
|
120
123
|
server:
|
121
124
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
122
125
|
date:
|
123
|
-
-
|
126
|
+
- Fri, 11 Mar 2011 18:50:37 GMT
|
124
127
|
connection:
|
125
128
|
- close
|
126
129
|
set-cookie:
|
127
|
-
- _recurly_session=
|
130
|
+
- _recurly_session=45d696eefbe4c9dbc3bbed0322252b50; domain=.recurly.local; path=/; HttpOnly
|
128
131
|
body: |
|
129
132
|
<?xml version="1.0" encoding="UTF-8"?>
|
130
133
|
<billing_info>
|
131
|
-
<account_code>invoice-create-
|
134
|
+
<account_code>invoice-create-1297746103</account_code>
|
132
135
|
<first_name>Verena</first_name>
|
133
136
|
<last_name>Test</last_name>
|
134
137
|
<address1>123 Test St</address1>
|
@@ -143,17 +146,17 @@
|
|
143
146
|
<credit_card>
|
144
147
|
<type>visa</type>
|
145
148
|
<last_four>1111</last_four>
|
146
|
-
<month type="integer">
|
149
|
+
<month type="integer">3</month>
|
147
150
|
<year type="integer">2012</year>
|
148
151
|
</credit_card>
|
149
|
-
<updated_at type="datetime">2011-
|
152
|
+
<updated_at type="datetime">2011-03-11T18:50:37Z</updated_at>
|
150
153
|
</billing_info>
|
151
154
|
|
152
155
|
http_version: "1.1"
|
153
156
|
- !ruby/struct:VCR::HTTPInteraction
|
154
157
|
request: !ruby/struct:VCR::Request
|
155
158
|
method: :post
|
156
|
-
uri: http://
|
159
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/invoice-create-1297746103/charges.xml
|
157
160
|
body: |
|
158
161
|
<?xml version="1.0" encoding="UTF-8"?>
|
159
162
|
<charge>
|
@@ -163,7 +166,7 @@
|
|
163
166
|
|
164
167
|
headers:
|
165
168
|
authorization:
|
166
|
-
- Basic
|
169
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
167
170
|
content-type:
|
168
171
|
- application/xml
|
169
172
|
accept:
|
@@ -180,7 +183,7 @@
|
|
180
183
|
cache-control:
|
181
184
|
- no-cache
|
182
185
|
x-runtime:
|
183
|
-
- "
|
186
|
+
- "224"
|
184
187
|
content-type:
|
185
188
|
- application/xml; charset=utf-8
|
186
189
|
content-length:
|
@@ -188,29 +191,29 @@
|
|
188
191
|
server:
|
189
192
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
190
193
|
date:
|
191
|
-
-
|
194
|
+
- Fri, 11 Mar 2011 18:50:39 GMT
|
192
195
|
connection:
|
193
196
|
- close
|
194
197
|
set-cookie:
|
195
|
-
- _recurly_session=
|
198
|
+
- _recurly_session=95aadc382547c28754c54b6f4d4a0c63; domain=.recurly.local; path=/; HttpOnly
|
196
199
|
body: |
|
197
200
|
<?xml version="1.0" encoding="UTF-8"?>
|
198
201
|
<charge type="charge">
|
199
|
-
<id>
|
200
|
-
<account_code>invoice-create-
|
202
|
+
<id>df42eb6baec0405c9610b93256c7723a</id>
|
203
|
+
<account_code>invoice-create-1297746103</account_code>
|
201
204
|
<amount_in_cents type="integer">1000</amount_in_cents>
|
202
|
-
<start_date type="datetime">2011-
|
205
|
+
<start_date type="datetime">2011-03-11T18:50:39Z</start_date>
|
203
206
|
<end_date nil="true" type="datetime"></end_date>
|
204
207
|
<invoice_number nil="true" type="integer"></invoice_number>
|
205
208
|
<description>charge description</description>
|
206
|
-
<created_at type="datetime">2011-
|
209
|
+
<created_at type="datetime">2011-03-11T18:50:39Z</created_at>
|
207
210
|
</charge>
|
208
211
|
|
209
212
|
http_version: "1.1"
|
210
213
|
- !ruby/struct:VCR::HTTPInteraction
|
211
214
|
request: !ruby/struct:VCR::Request
|
212
215
|
method: :post
|
213
|
-
uri: http://
|
216
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/invoice-create-1297746103/charges.xml
|
214
217
|
body: |
|
215
218
|
<?xml version="1.0" encoding="UTF-8"?>
|
216
219
|
<charge>
|
@@ -220,7 +223,7 @@
|
|
220
223
|
|
221
224
|
headers:
|
222
225
|
authorization:
|
223
|
-
- Basic
|
226
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
224
227
|
content-type:
|
225
228
|
- application/xml
|
226
229
|
accept:
|
@@ -237,7 +240,7 @@
|
|
237
240
|
cache-control:
|
238
241
|
- no-cache
|
239
242
|
x-runtime:
|
240
|
-
- "
|
243
|
+
- "230"
|
241
244
|
content-type:
|
242
245
|
- application/xml; charset=utf-8
|
243
246
|
content-length:
|
@@ -245,29 +248,29 @@
|
|
245
248
|
server:
|
246
249
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
247
250
|
date:
|
248
|
-
-
|
251
|
+
- Fri, 11 Mar 2011 18:50:42 GMT
|
249
252
|
connection:
|
250
253
|
- close
|
251
254
|
set-cookie:
|
252
|
-
- _recurly_session=
|
255
|
+
- _recurly_session=91874e9b0853cb20d1dd9a7e34fe13b5; domain=.recurly.local; path=/; HttpOnly
|
253
256
|
body: |
|
254
257
|
<?xml version="1.0" encoding="UTF-8"?>
|
255
258
|
<charge type="charge">
|
256
|
-
<id>
|
257
|
-
<account_code>invoice-create-
|
259
|
+
<id>7be4f307999543b3836010ab35a60148</id>
|
260
|
+
<account_code>invoice-create-1297746103</account_code>
|
258
261
|
<amount_in_cents type="integer">1500</amount_in_cents>
|
259
|
-
<start_date type="datetime">2011-
|
262
|
+
<start_date type="datetime">2011-03-11T18:50:42Z</start_date>
|
260
263
|
<end_date nil="true" type="datetime"></end_date>
|
261
264
|
<invoice_number nil="true" type="integer"></invoice_number>
|
262
265
|
<description>charge description</description>
|
263
|
-
<created_at type="datetime">2011-
|
266
|
+
<created_at type="datetime">2011-03-11T18:50:42Z</created_at>
|
264
267
|
</charge>
|
265
268
|
|
266
269
|
http_version: "1.1"
|
267
270
|
- !ruby/struct:VCR::HTTPInteraction
|
268
271
|
request: !ruby/struct:VCR::Request
|
269
272
|
method: :post
|
270
|
-
uri: http://
|
273
|
+
uri: http://api-test-123%40litle.com:82a98ee0c1c2495789775177babfadb7@app.recurly.local:3000/accounts/invoice-create-1297746103/invoices.xml
|
271
274
|
body: |
|
272
275
|
<?xml version="1.0" encoding="UTF-8"?>
|
273
276
|
<invoice>
|
@@ -275,7 +278,7 @@
|
|
275
278
|
|
276
279
|
headers:
|
277
280
|
authorization:
|
278
|
-
- Basic
|
281
|
+
- Basic YXBpLXRlc3QtMTIzQGxpdGxlLmNvbTo4MmE5OGVlMGMxYzI0OTU3ODk3NzUxNzdiYWJmYWRiNw==
|
279
282
|
content-type:
|
280
283
|
- application/xml
|
281
284
|
accept:
|
@@ -292,9 +295,9 @@
|
|
292
295
|
cache-control:
|
293
296
|
- no-cache
|
294
297
|
location:
|
295
|
-
- http://
|
298
|
+
- http://app.recurly.local:3000/invoices/5c7112b0d1444f70b53860b06f571cdf
|
296
299
|
x-runtime:
|
297
|
-
- "
|
300
|
+
- "712"
|
298
301
|
content-type:
|
299
302
|
- application/xml; charset=utf-8
|
300
303
|
content-length:
|
@@ -302,18 +305,18 @@
|
|
302
305
|
server:
|
303
306
|
- WEBrick/1.3.1 (Ruby/1.9.2/2010-08-18)
|
304
307
|
date:
|
305
|
-
-
|
308
|
+
- Fri, 11 Mar 2011 18:50:45 GMT
|
306
309
|
connection:
|
307
310
|
- close
|
308
311
|
set-cookie:
|
309
|
-
- _recurly_session=
|
312
|
+
- _recurly_session=dcf3ff82425cde8d644dd8df2355d5f6; domain=.recurly.local; path=/; HttpOnly
|
310
313
|
body: |
|
311
314
|
<?xml version="1.0" encoding="UTF-8"?>
|
312
315
|
<invoice>
|
313
|
-
<id>
|
314
|
-
<account_code>invoice-create-
|
315
|
-
<date type="datetime">2011-
|
316
|
-
<invoice_number type="integer">
|
316
|
+
<id>5c7112b0d1444f70b53860b06f571cdf</id>
|
317
|
+
<account_code>invoice-create-1297746103</account_code>
|
318
|
+
<date type="datetime">2011-03-11T18:50:45Z</date>
|
319
|
+
<invoice_number type="integer">1527</invoice_number>
|
317
320
|
<vat_number></vat_number>
|
318
321
|
<status>open</status>
|
319
322
|
<subtotal_in_cents type="integer">2500</subtotal_in_cents>
|
@@ -324,23 +327,23 @@
|
|
324
327
|
<discount_in_cents type="integer">0</discount_in_cents>
|
325
328
|
<line_items type="array">
|
326
329
|
<line_item>
|
327
|
-
<id>
|
330
|
+
<id>df42eb6baec0405c9610b93256c7723a</id>
|
328
331
|
<type>charge</type>
|
329
332
|
<amount_in_cents type="integer">1000</amount_in_cents>
|
330
|
-
<start_date type="datetime">2011-
|
333
|
+
<start_date type="datetime">2011-03-11T18:50:39Z</start_date>
|
331
334
|
<end_date nil="true" type="datetime"></end_date>
|
332
335
|
<description>charge description</description>
|
333
|
-
<created_at type="datetime">2011-
|
336
|
+
<created_at type="datetime">2011-03-11T18:50:39Z</created_at>
|
334
337
|
<applied_coupon_code></applied_coupon_code>
|
335
338
|
</line_item>
|
336
339
|
<line_item>
|
337
|
-
<id>
|
340
|
+
<id>7be4f307999543b3836010ab35a60148</id>
|
338
341
|
<type>charge</type>
|
339
342
|
<amount_in_cents type="integer">1500</amount_in_cents>
|
340
|
-
<start_date type="datetime">2011-
|
343
|
+
<start_date type="datetime">2011-03-11T18:50:42Z</start_date>
|
341
344
|
<end_date nil="true" type="datetime"></end_date>
|
342
345
|
<description>charge description</description>
|
343
|
-
<created_at type="datetime">2011-
|
346
|
+
<created_at type="datetime">2011-03-11T18:50:42Z</created_at>
|
344
347
|
<applied_coupon_code></applied_coupon_code>
|
345
348
|
</line_item>
|
346
349
|
</line_items>
|