-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #90 from recurly/preview_associations
Create resources based on the element if no href links to the object
- Loading branch information
Showing
4 changed files
with
103 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
POST https://api.recurly.com/v2/subscriptions/123456789012345678901234567890ab/preview HTTP/1.1 | ||
Accept: application/xml | ||
Authorization: Basic YXBpa2V5Og== | ||
User-Agent: recurly-python/{version} | ||
Content-Type: application/xml; charset=utf-8 | ||
|
||
<?xml version='1.0' encoding='UTF-8'?> | ||
<subscription> | ||
<quantity type="integer">2</quantity> | ||
</subscription> | ||
HTTP/1.1 200 OK | ||
Content-Type: application/xml; charset=utf-8 | ||
|
||
<?xml version="1.0" encoding="UTF-8"?> | ||
<subscription | ||
href="https://api.recurly.com/v2/subscriptions/123456789012345678901234567890ab"> | ||
<uuid>123456789012345678901234567890ab</uuid> | ||
<account href="https://api.recurly.com/v2/accounts/subscribemock"/> | ||
<plan href="https://api.recurly.com/v2/plans/basicplan"> | ||
<plan_code>basicplan</plan_code> | ||
<name>Basic Plan</name> | ||
</plan> | ||
<state>active</state> | ||
<quantity type="integer">1</quantity> | ||
<currency>EUR</currency> | ||
<unit_amount_in_cents type="integer">1000</unit_amount_in_cents> | ||
<activated_at type="datetime">2011-05-27T07:00:00Z</activated_at> | ||
<canceled_at nil="nil"></canceled_at> | ||
<expires_at nil="nil"></expires_at> | ||
<current_period_started_at type="datetime">2011-06-27T07:00:00Z</current_period_started_at> | ||
<current_period_ends_at type="datetime">2010-07-27T07:00:00Z</current_period_ends_at> | ||
<trial_started_at nil="nil"></trial_started_at> | ||
<trial_ends_at nil="nil"></trial_ends_at> | ||
<tax_in_cents type="integer">0</tax_in_cents> | ||
<tax_type>usst</tax_type> | ||
<subscription_add_ons type="array"> | ||
</subscription_add_ons> | ||
<invoice href=""> | ||
<account href="https://api.recurly.com/v2/accounts/subscribemock"/> | ||
<subscription href="https://api.recurly.com/v2/subscriptions/123456789012345678901234567890ab"/> | ||
<uuid>4ba1531325014b4f969cd13676f514d8</uuid> | ||
<account_code>subscribemock</account_code> | ||
<total_in_cents>2000</total_in_cents> | ||
<created_at type="nil"></created_at> | ||
<line_items type="array"> | ||
<adjustment> | ||
<uuid>4ba1531325014b4f969cd13676f51438</uuid> | ||
<account_code>chargemock</account_code> | ||
<unit_amount_in_cents type="integer">1000</unit_amount_in_cents> | ||
<amount_in_cents type="integer">2000</amount_in_cents> | ||
<quantity>2</quantity> | ||
<currency>USD</currency> | ||
<start_date type="datetime">2011-06-27T07:00:00Z</start_date> | ||
<end_date type="datetime">2010-07-27T07:00:00Z</end_date> | ||
<description>Basic Plan charge</description> | ||
<created_at type="nil"></created_at> | ||
</adjustment> | ||
</line_items> | ||
</invoice> | ||
</subscription> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters