chargify_api_ares 1.1.0.pre → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.env +4 -0
- data/.gitignore +1 -0
- data/.rspec +1 -0
- data/.travis.yml +9 -0
- data/Gemfile +1 -1
- data/Gemfile.lock +7 -1
- data/HISTORY.md +9 -0
- data/README.md +1 -1
- data/chargify_api_ares.gemspec +4 -2
- data/examples/metadata.rb +58 -0
- data/examples/metafields.rb +32 -0
- data/lib/chargify_api_ares.rb +4 -2
- data/lib/chargify_api_ares/behaviors/inspectable.rb +33 -0
- data/lib/chargify_api_ares/behaviors/metadata.rb +61 -0
- data/lib/chargify_api_ares/behaviors/metafield.rb +30 -0
- data/lib/chargify_api_ares/resources/customer_metafield.rb +14 -1
- data/lib/chargify_api_ares/resources/invoice.rb +4 -4
- data/lib/chargify_api_ares/resources/subscription.rb +26 -3
- data/lib/chargify_api_ares/resources/subscription_metadata.rb +17 -0
- data/lib/chargify_api_ares/resources/subscription_metafield.rb +14 -1
- data/spec/cassettes/subscription/find.yml +266 -0
- data/spec/cassettes/subscription_metadata/create.yml +78 -0
- data/spec/cassettes/subscription_metadata/list-after-create.yml +77 -0
- data/spec/cassettes/subscription_metadata/list.yml +71 -0
- data/spec/factories.rb +1 -0
- data/spec/resources/customer_metafield_spec.rb +64 -0
- data/spec/resources/customer_spec.rb +4 -4
- data/spec/resources/subscription_metadata_spec.rb +54 -0
- data/spec/resources/subscription_metafield_spec.rb +63 -0
- data/spec/resources/subscription_spec.rb +27 -0
- data/spec/spec_helper.rb +14 -2
- metadata +78 -31
- data/lib/chargify_api_ares/metafield_xml_formatter.rb +0 -10
- data/lib/chargify_api_ares/resources/metafield.rb +0 -67
- data/spec/spec.opts +0 -2
@@ -0,0 +1,17 @@
|
|
1
|
+
module Chargify
|
2
|
+
class SubscriptionMetadata < Base
|
3
|
+
include ::Chargify::Behaviors::Inspectable
|
4
|
+
include ::Chargify::Behaviors::Metadata
|
5
|
+
|
6
|
+
self.inspect_class = "resource_id: integer, current_name: string, name: string, value: string"
|
7
|
+
self.inspect_instance = Proc.new { |s| [[:resource_id, s.prefix_options[:resource_id]], [:current_name, s.current_name], [:name, s.name], [:value, s.value]] }
|
8
|
+
self.prefix = '/subscriptions/:resource_id/'
|
9
|
+
self.endpoint_name = 'metadata'
|
10
|
+
|
11
|
+
schema do
|
12
|
+
attribute 'current_name', :string
|
13
|
+
attribute 'name', :string
|
14
|
+
attribute 'value', :string
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -1,5 +1,18 @@
|
|
1
1
|
module Chargify
|
2
|
-
class SubscriptionMetafield <
|
2
|
+
class SubscriptionMetafield < Base
|
3
|
+
include ::Chargify::Behaviors::Inspectable
|
4
|
+
include ::Chargify::Behaviors::Metafield
|
5
|
+
include ::Chargify::Behaviors::Metadata
|
6
|
+
|
3
7
|
self.prefix = "/subscriptions/"
|
8
|
+
|
9
|
+
self.inspect_class = "current_name: string, name: string, scope: { hosted: [], csv: boolean }"
|
10
|
+
self.inspect_instance = Proc.new {|s| [[:current_name, s.current_name], [:name, s.name]] }
|
11
|
+
self.endpoint_name = 'metafields'
|
12
|
+
|
13
|
+
schema do
|
14
|
+
attribute 'current_name', :string
|
15
|
+
attribute 'name', :string
|
16
|
+
end
|
4
17
|
end
|
5
18
|
end
|
@@ -0,0 +1,266 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://acme_test_key:X@acme.chargify.dev/subscriptions.xml
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
authorization:
|
11
|
+
- Basic YWNtZV90ZXN0X2tleTpY
|
12
|
+
accept:
|
13
|
+
- application/xml
|
14
|
+
accept-encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
user-agent:
|
17
|
+
- Ruby
|
18
|
+
response:
|
19
|
+
status:
|
20
|
+
code: 200
|
21
|
+
message: OK
|
22
|
+
headers:
|
23
|
+
x-frame-options:
|
24
|
+
- SAMEORIGIN
|
25
|
+
content-type:
|
26
|
+
- application/xml; charset=utf-8
|
27
|
+
x-meta-request-version:
|
28
|
+
- 0.3.3
|
29
|
+
x-ratelimit-limit:
|
30
|
+
- '1000000'
|
31
|
+
x-ratelimit-remaining:
|
32
|
+
- '999989'
|
33
|
+
x-ratelimit-reset:
|
34
|
+
- '1408579200'
|
35
|
+
x-ua-compatible:
|
36
|
+
- IE=Edge
|
37
|
+
etag:
|
38
|
+
- '"d792e14bb55540e5e197604a6a3715df"'
|
39
|
+
cache-control:
|
40
|
+
- max-age=0, private, must-revalidate
|
41
|
+
p3p:
|
42
|
+
- CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"
|
43
|
+
set-cookie:
|
44
|
+
- _chargify_session=BAh7CEkiD3Nlc3Npb25faWQGOgZFVEkiJTYzYjEzOWUyYTBmNzRkZmY0OTM2NjBlMjU1ODRhZDk0BjsAVEkiF3NlbGxlcl9jcmVkZW50aWFscwY7AEZJIgGAMzc2NjRiYTU1MjUxNTgyYWU2YTg2MmU5ZDk0YzllODU3ZGIyZjQ0Y2M0YmZlMTU4N2Y4MjUzODY2MzBkNWM5ZWIyM2Q2NzVlYmViZTc2ZjU1MTk4YjIyNTJlYTYxYzY3NzkyNzk1NGRmMTU4OTA3NmM3MGFhYzA0NTI5N2Y5ZmIGOwBGSSIac2VsbGVyX2NyZWRlbnRpYWxzX2lkBjsARmkH--8ad350c97ec34870db6ec966836951160ec5909f;
|
45
|
+
domain=.chargify.dev; path=/; HttpOnly
|
46
|
+
x-request-id:
|
47
|
+
- e13206c19fb48daf2375032c3713bb3b
|
48
|
+
x-runtime:
|
49
|
+
- '0.138341'
|
50
|
+
connection:
|
51
|
+
- close
|
52
|
+
server:
|
53
|
+
- thin 1.6.2 codename Doc Brown
|
54
|
+
date:
|
55
|
+
- Wed, 20 Aug 2014 03:32:09 GMT
|
56
|
+
transfer-encoding:
|
57
|
+
- chunked
|
58
|
+
body:
|
59
|
+
encoding: UTF-8
|
60
|
+
string: |
|
61
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
62
|
+
<subscriptions type="array">
|
63
|
+
<subscription>
|
64
|
+
<activated_at type="datetime" nil="true"/>
|
65
|
+
<balance_in_cents type="integer">0</balance_in_cents>
|
66
|
+
<cancel_at_end_of_period type="boolean">false</cancel_at_end_of_period>
|
67
|
+
<canceled_at type="datetime" nil="true"/>
|
68
|
+
<cancellation_message nil="true"/>
|
69
|
+
<created_at type="datetime">2014-08-19T08:40:44-04:00</created_at>
|
70
|
+
<current_period_ends_at type="datetime">2014-09-19T08:40:44-04:00</current_period_ends_at>
|
71
|
+
<expires_at type="datetime" nil="true"/>
|
72
|
+
<id type="integer">23</id>
|
73
|
+
<next_assessment_at type="datetime">2014-09-19T08:40:44-04:00</next_assessment_at>
|
74
|
+
<payment_collection_method>automatic</payment_collection_method>
|
75
|
+
<state>trialing</state>
|
76
|
+
<trial_ended_at type="datetime">2014-09-19T08:40:44-04:00</trial_ended_at>
|
77
|
+
<trial_started_at type="datetime">2014-08-19T08:40:44-04:00</trial_started_at>
|
78
|
+
<updated_at type="datetime">2014-08-19T10:52:48-04:00</updated_at>
|
79
|
+
<current_period_started_at type="datetime">2014-08-19T08:40:44-04:00</current_period_started_at>
|
80
|
+
<previous_state>trialing</previous_state>
|
81
|
+
<signup_payment_id type="integer">49</signup_payment_id>
|
82
|
+
<signup_revenue>0.00</signup_revenue>
|
83
|
+
<delayed_cancel_at nil="true"/>
|
84
|
+
<coupon_code nil="true"/>
|
85
|
+
<total_revenue_in_cents type="integer">0</total_revenue_in_cents>
|
86
|
+
<product_price_in_cents type="integer">2400</product_price_in_cents>
|
87
|
+
<product_version_number type="integer">1</product_version_number>
|
88
|
+
<payment_type>credit_card</payment_type>
|
89
|
+
<customer>
|
90
|
+
<address>vern st</address>
|
91
|
+
<address_2></address_2>
|
92
|
+
<city>vern city</city>
|
93
|
+
<country>GB</country>
|
94
|
+
<created_at type="datetime">2014-08-19T08:40:44-04:00</created_at>
|
95
|
+
<email>vern@example.com</email>
|
96
|
+
<first_name>Nathan</first_name>
|
97
|
+
<id type="integer">23</id>
|
98
|
+
<last_name>Verni</last_name>
|
99
|
+
<organization>Chargify</organization>
|
100
|
+
<phone></phone>
|
101
|
+
<portal_customer_created_at type="datetime" nil="true"/>
|
102
|
+
<portal_invite_last_accepted_at type="datetime" nil="true"/>
|
103
|
+
<portal_invite_last_sent_at type="datetime" nil="true"/>
|
104
|
+
<reference>vern</reference>
|
105
|
+
<state>ANS</state>
|
106
|
+
<updated_at type="datetime">2014-08-19T08:40:44-04:00</updated_at>
|
107
|
+
<verified type="boolean">false</verified>
|
108
|
+
<zip>11111</zip>
|
109
|
+
</customer>
|
110
|
+
<product>
|
111
|
+
<accounting_code nil="true"/>
|
112
|
+
<archived_at type="datetime" nil="true"/>
|
113
|
+
<created_at type="datetime">2014-08-19T08:32:30-04:00</created_at>
|
114
|
+
<description>Culpa illum quia reiciendis consequatur vitae. Ut sunt dolor consectetur excepturi odio maxime. Temporibus eius adipisci est illum eaque praesentium numquam.</description>
|
115
|
+
<expiration_interval type="integer" nil="true"/>
|
116
|
+
<expiration_interval_unit nil="true"/>
|
117
|
+
<handle>basic</handle>
|
118
|
+
<id type="integer">20</id>
|
119
|
+
<initial_charge_in_cents type="integer" nil="true"/>
|
120
|
+
<interval type="integer">1</interval>
|
121
|
+
<interval_unit>month</interval_unit>
|
122
|
+
<name>Basic</name>
|
123
|
+
<price_in_cents type="integer">2400</price_in_cents>
|
124
|
+
<request_credit_card type="boolean">true</request_credit_card>
|
125
|
+
<require_credit_card type="boolean">true</require_credit_card>
|
126
|
+
<return_params nil="true"/>
|
127
|
+
<return_url nil="true"/>
|
128
|
+
<taxable type="boolean">false</taxable>
|
129
|
+
<trial_interval type="integer">1</trial_interval>
|
130
|
+
<trial_interval_unit>month</trial_interval_unit>
|
131
|
+
<trial_price_in_cents type="integer">0</trial_price_in_cents>
|
132
|
+
<update_return_url nil="true"/>
|
133
|
+
<updated_at type="datetime">2014-08-19T08:32:30-04:00</updated_at>
|
134
|
+
<product_family>
|
135
|
+
<accounting_code nil="true"/>
|
136
|
+
<description nil="true"/>
|
137
|
+
<handle>acme-online</handle>
|
138
|
+
<id type="integer">3</id>
|
139
|
+
<name>Acme Online</name>
|
140
|
+
</product_family>
|
141
|
+
</product>
|
142
|
+
<credit_card>
|
143
|
+
<billing_address>vern st</billing_address>
|
144
|
+
<billing_address_2></billing_address_2>
|
145
|
+
<billing_city>vern city</billing_city>
|
146
|
+
<billing_country>US</billing_country>
|
147
|
+
<billing_state>AL</billing_state>
|
148
|
+
<billing_zip>11111</billing_zip>
|
149
|
+
<card_type>bogus</card_type>
|
150
|
+
<current_vault>bogus</current_vault>
|
151
|
+
<customer_id type="integer">23</customer_id>
|
152
|
+
<customer_vault_token nil="true"/>
|
153
|
+
<expiration_month type="integer">8</expiration_month>
|
154
|
+
<expiration_year type="integer">2021</expiration_year>
|
155
|
+
<first_name>Nathan</first_name>
|
156
|
+
<id type="integer">23</id>
|
157
|
+
<last_name>Verni</last_name>
|
158
|
+
<masked_card_number>XXXX-XXXX-XXXX-1</masked_card_number>
|
159
|
+
<vault_token>1</vault_token>
|
160
|
+
<payment_type>credit_card</payment_type>
|
161
|
+
</credit_card>
|
162
|
+
</subscription>
|
163
|
+
<subscription>
|
164
|
+
<activated_at type="datetime">2014-08-19T08:38:37-04:00</activated_at>
|
165
|
+
<balance_in_cents type="integer">0</balance_in_cents>
|
166
|
+
<cancel_at_end_of_period type="boolean">false</cancel_at_end_of_period>
|
167
|
+
<canceled_at type="datetime" nil="true"/>
|
168
|
+
<cancellation_message nil="true"/>
|
169
|
+
<created_at type="datetime">2014-08-19T08:38:36-04:00</created_at>
|
170
|
+
<current_period_ends_at type="datetime">2014-09-19T08:38:36-04:00</current_period_ends_at>
|
171
|
+
<expires_at type="datetime" nil="true"/>
|
172
|
+
<id type="integer">22</id>
|
173
|
+
<next_assessment_at type="datetime">2014-09-19T08:38:36-04:00</next_assessment_at>
|
174
|
+
<payment_collection_method>automatic</payment_collection_method>
|
175
|
+
<state>active</state>
|
176
|
+
<trial_ended_at type="datetime" nil="true"/>
|
177
|
+
<trial_started_at type="datetime" nil="true"/>
|
178
|
+
<updated_at type="datetime">2014-08-19T10:52:27-04:00</updated_at>
|
179
|
+
<current_period_started_at type="datetime">2014-08-19T08:38:36-04:00</current_period_started_at>
|
180
|
+
<previous_state>active</previous_state>
|
181
|
+
<signup_payment_id type="integer">48</signup_payment_id>
|
182
|
+
<signup_revenue>0.00</signup_revenue>
|
183
|
+
<delayed_cancel_at nil="true"/>
|
184
|
+
<coupon_code nil="true"/>
|
185
|
+
<total_revenue_in_cents type="integer">0</total_revenue_in_cents>
|
186
|
+
<product_price_in_cents type="integer">0</product_price_in_cents>
|
187
|
+
<product_version_number type="integer">1</product_version_number>
|
188
|
+
<payment_type>credit_card</payment_type>
|
189
|
+
<customer>
|
190
|
+
<address>2126 lakeside lofts cir</address>
|
191
|
+
<address_2></address_2>
|
192
|
+
<city>Cary</city>
|
193
|
+
<country>US</country>
|
194
|
+
<created_at type="datetime">2014-08-19T08:38:36-04:00</created_at>
|
195
|
+
<email>jeremy.w.rowe@gmail.com</email>
|
196
|
+
<first_name>Jeremy</first_name>
|
197
|
+
<id type="integer">22</id>
|
198
|
+
<last_name>Rowe</last_name>
|
199
|
+
<organization>chargify</organization>
|
200
|
+
<phone></phone>
|
201
|
+
<portal_customer_created_at type="datetime" nil="true"/>
|
202
|
+
<portal_invite_last_accepted_at type="datetime" nil="true"/>
|
203
|
+
<portal_invite_last_sent_at type="datetime" nil="true"/>
|
204
|
+
<reference>jdawg</reference>
|
205
|
+
<state>AL</state>
|
206
|
+
<updated_at type="datetime">2014-08-19T08:38:36-04:00</updated_at>
|
207
|
+
<verified type="boolean">false</verified>
|
208
|
+
<zip>27513</zip>
|
209
|
+
</customer>
|
210
|
+
<product>
|
211
|
+
<accounting_code nil="true"/>
|
212
|
+
<archived_at type="datetime" nil="true"/>
|
213
|
+
<created_at type="datetime">2014-08-19T08:32:30-04:00</created_at>
|
214
|
+
<description>Id nostrum fugit. Voluptate et qui. Iure quas enim id impedit odit sit expedita.</description>
|
215
|
+
<expiration_interval type="integer" nil="true"/>
|
216
|
+
<expiration_interval_unit nil="true"/>
|
217
|
+
<handle>free</handle>
|
218
|
+
<id type="integer">19</id>
|
219
|
+
<initial_charge_in_cents type="integer" nil="true"/>
|
220
|
+
<interval type="integer">1</interval>
|
221
|
+
<interval_unit>month</interval_unit>
|
222
|
+
<name>Free</name>
|
223
|
+
<price_in_cents type="integer">0</price_in_cents>
|
224
|
+
<request_credit_card type="boolean">true</request_credit_card>
|
225
|
+
<require_credit_card type="boolean">true</require_credit_card>
|
226
|
+
<return_params nil="true"/>
|
227
|
+
<return_url nil="true"/>
|
228
|
+
<taxable type="boolean">false</taxable>
|
229
|
+
<trial_interval type="integer" nil="true"/>
|
230
|
+
<trial_interval_unit nil="true"/>
|
231
|
+
<trial_price_in_cents type="integer" nil="true"/>
|
232
|
+
<update_return_url nil="true"/>
|
233
|
+
<updated_at type="datetime">2014-08-19T08:32:30-04:00</updated_at>
|
234
|
+
<product_family>
|
235
|
+
<accounting_code nil="true"/>
|
236
|
+
<description nil="true"/>
|
237
|
+
<handle>acme-online</handle>
|
238
|
+
<id type="integer">3</id>
|
239
|
+
<name>Acme Online</name>
|
240
|
+
</product_family>
|
241
|
+
</product>
|
242
|
+
<credit_card>
|
243
|
+
<billing_address>2126 Lakeside Lofts Cir</billing_address>
|
244
|
+
<billing_address_2></billing_address_2>
|
245
|
+
<billing_city>Cary</billing_city>
|
246
|
+
<billing_country>US</billing_country>
|
247
|
+
<billing_state>AK</billing_state>
|
248
|
+
<billing_zip>27513</billing_zip>
|
249
|
+
<card_type>bogus</card_type>
|
250
|
+
<current_vault>bogus</current_vault>
|
251
|
+
<customer_id type="integer">22</customer_id>
|
252
|
+
<customer_vault_token nil="true"/>
|
253
|
+
<expiration_month type="integer">1</expiration_month>
|
254
|
+
<expiration_year type="integer">2018</expiration_year>
|
255
|
+
<first_name>Jeremy <3</first_name>
|
256
|
+
<id type="integer">22</id>
|
257
|
+
<last_name>Rowe</last_name>
|
258
|
+
<masked_card_number>XXXX-XXXX-XXXX-1</masked_card_number>
|
259
|
+
<vault_token>1</vault_token>
|
260
|
+
<payment_type>credit_card</payment_type>
|
261
|
+
</credit_card>
|
262
|
+
</subscription>
|
263
|
+
</subscriptions>
|
264
|
+
http_version: '1.1'
|
265
|
+
recorded_at: Wed, 20 Aug 2014 03:32:09 GMT
|
266
|
+
recorded_with: VCR 2.9.2
|
@@ -0,0 +1,78 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: post
|
5
|
+
uri: http://acme_test_key:X@acme.chargify.dev/subscriptions/22/metadata.xml
|
6
|
+
body:
|
7
|
+
encoding: UTF-8
|
8
|
+
string: |
|
9
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
10
|
+
<metadata>
|
11
|
+
<name>favorite color</name>
|
12
|
+
<value>red</value>
|
13
|
+
</metadata>
|
14
|
+
headers:
|
15
|
+
authorization:
|
16
|
+
- Basic YWNtZV90ZXN0X2tleTpY
|
17
|
+
content-type:
|
18
|
+
- application/xml
|
19
|
+
accept-encoding:
|
20
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
21
|
+
accept:
|
22
|
+
- '*/*'
|
23
|
+
user-agent:
|
24
|
+
- Ruby
|
25
|
+
response:
|
26
|
+
status:
|
27
|
+
code: 200
|
28
|
+
message: OK
|
29
|
+
headers:
|
30
|
+
x-frame-options:
|
31
|
+
- SAMEORIGIN
|
32
|
+
content-type:
|
33
|
+
- application/xml; charset=utf-8
|
34
|
+
x-meta-request-version:
|
35
|
+
- 0.3.3
|
36
|
+
x-ratelimit-limit:
|
37
|
+
- '1000000'
|
38
|
+
x-ratelimit-remaining:
|
39
|
+
- '999992'
|
40
|
+
x-ratelimit-reset:
|
41
|
+
- '1408579200'
|
42
|
+
x-ua-compatible:
|
43
|
+
- IE=Edge
|
44
|
+
etag:
|
45
|
+
- '"8978e8b3fa40ae07917c2bf207f94bb7"'
|
46
|
+
cache-control:
|
47
|
+
- max-age=0, private, must-revalidate
|
48
|
+
p3p:
|
49
|
+
- CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"
|
50
|
+
set-cookie:
|
51
|
+
- _chargify_session=BAh7CEkiD3Nlc3Npb25faWQGOgZFVEkiJWExNzM3YmQ1M2M1MjNjMjE5ZWI0ZDdmM2ZjZmZiN2NlBjsAVEkiF3NlbGxlcl9jcmVkZW50aWFscwY7AEZJIgGAMDYxM2U3ZDA4MmM0ZGMyZTkzMjJhMTBjMGY0NjQzMmQ5NGM5NjJjNjE2YmRjMzk0MDRkYTRkZTc4MzIyNTM2YjQyZmNiNzU0MjIwMmQ4ZDU5Yjg4YjgzNmI5NDI5MTIxMTE4YTNlZDFjZTliNzA2OTgzMzI5MjNlMDM4Y2U4ODUGOwBGSSIac2VsbGVyX2NyZWRlbnRpYWxzX2lkBjsARmkH--cafdef26202c6f0240cac62227ecc8ce22e582e6;
|
52
|
+
domain=.chargify.dev; path=/; HttpOnly
|
53
|
+
x-request-id:
|
54
|
+
- fe1ac35a2915fe7ee0d5ca40c2b94d62
|
55
|
+
x-runtime:
|
56
|
+
- '0.318252'
|
57
|
+
connection:
|
58
|
+
- close
|
59
|
+
server:
|
60
|
+
- thin 1.6.2 codename Doc Brown
|
61
|
+
date:
|
62
|
+
- Wed, 20 Aug 2014 03:24:51 GMT
|
63
|
+
transfer-encoding:
|
64
|
+
- chunked
|
65
|
+
body:
|
66
|
+
encoding: UTF-8
|
67
|
+
string: |
|
68
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
69
|
+
<metadata type="array">
|
70
|
+
<metadatum>
|
71
|
+
<resource-id type="integer">22</resource-id>
|
72
|
+
<value>red</value>
|
73
|
+
<name>favorite color</name>
|
74
|
+
</metadatum>
|
75
|
+
</metadata>
|
76
|
+
http_version: '1.1'
|
77
|
+
recorded_at: Wed, 20 Aug 2014 03:24:51 GMT
|
78
|
+
recorded_with: VCR 2.9.2
|
@@ -0,0 +1,77 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://acme_test_key:X@acme.chargify.dev/subscriptions/22/metadata.xml
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
authorization:
|
11
|
+
- Basic YWNtZV90ZXN0X2tleTpY
|
12
|
+
accept:
|
13
|
+
- application/xml
|
14
|
+
accept-encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
user-agent:
|
17
|
+
- Ruby
|
18
|
+
response:
|
19
|
+
status:
|
20
|
+
code: 200
|
21
|
+
message: OK
|
22
|
+
headers:
|
23
|
+
x-frame-options:
|
24
|
+
- SAMEORIGIN
|
25
|
+
content-type:
|
26
|
+
- application/xml; charset=utf-8
|
27
|
+
x-meta-request-version:
|
28
|
+
- 0.3.3
|
29
|
+
x-ratelimit-limit:
|
30
|
+
- '1000000'
|
31
|
+
x-ratelimit-remaining:
|
32
|
+
- '999991'
|
33
|
+
x-ratelimit-reset:
|
34
|
+
- '1408579200'
|
35
|
+
x-ua-compatible:
|
36
|
+
- IE=Edge
|
37
|
+
etag:
|
38
|
+
- '"b12cf71c34241f3b8ef1c893401c6645"'
|
39
|
+
cache-control:
|
40
|
+
- max-age=0, private, must-revalidate
|
41
|
+
p3p:
|
42
|
+
- CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"
|
43
|
+
set-cookie:
|
44
|
+
- _chargify_session=BAh7CEkiD3Nlc3Npb25faWQGOgZFVEkiJTlmNzY3YzJhYmQ1OGI4MzMxNWNhNmI2YWQ5OWY3OWFjBjsAVEkiF3NlbGxlcl9jcmVkZW50aWFscwY7AEZJIgGAYjEyNjk1MmVhMDAzMDkyNGMwYzczMmNjYjU4NzMyNjYzZDQ3MjJjM2QxNjE1OGVjNjViODBjYzZiYzZkMzlhMTM4OWM0YWQyZjA0NWEyMzQyZDZkNjM2YWNkNjRkNDk0NGI0OWNkZWU2OWU2YmYxMmE4NWY3NjA0ZTFiYjBjMWIGOwBGSSIac2VsbGVyX2NyZWRlbnRpYWxzX2lkBjsARmkH--476471b0db187af33fda6ef554f7ffc6fcf43436;
|
45
|
+
domain=.chargify.dev; path=/; HttpOnly
|
46
|
+
x-request-id:
|
47
|
+
- ace8a1104eaa6ac01256237cd077572f
|
48
|
+
x-runtime:
|
49
|
+
- '0.064855'
|
50
|
+
connection:
|
51
|
+
- close
|
52
|
+
server:
|
53
|
+
- thin 1.6.2 codename Doc Brown
|
54
|
+
date:
|
55
|
+
- Wed, 20 Aug 2014 03:27:24 GMT
|
56
|
+
transfer-encoding:
|
57
|
+
- chunked
|
58
|
+
body:
|
59
|
+
encoding: UTF-8
|
60
|
+
string: |
|
61
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
62
|
+
<results>
|
63
|
+
<total-count type="integer">1</total-count>
|
64
|
+
<current-page type="integer">1</current-page>
|
65
|
+
<total-pages type="integer">1</total-pages>
|
66
|
+
<per-page type="integer">20</per-page>
|
67
|
+
<metadata type="array">
|
68
|
+
<metadatum>
|
69
|
+
<resource-id type="integer">22</resource-id>
|
70
|
+
<value>red</value>
|
71
|
+
<name>favorite color</name>
|
72
|
+
</metadatum>
|
73
|
+
</metadata>
|
74
|
+
</results>
|
75
|
+
http_version: '1.1'
|
76
|
+
recorded_at: Wed, 20 Aug 2014 03:27:24 GMT
|
77
|
+
recorded_with: VCR 2.9.2
|