Detecting declined charges from XML

Dan Kamins's Avatar

Dan Kamins

01 Oct, 2010 12:58 AM

We want our web site to detect when a user is in the state of having their monthly charge declined, and to display a warning to the user.

What in the XML will help us detect this state?

I am guessing:

  1. Find the second <invoice> record under subscriptions.subscription[0].invoices.
    (The first <invoice> seems to show the current billing period, which appears to start even if the previous one has not billed successfully).

  2. Check this invoice's <paidTransactionId> field. If there is something there, consider it paid. If empty, consider it unpaid.

But this feels cargo-cultish and maybe not the best way. What do you recommend?

Thank you.

  1. Support Staff 1 Posted by Marc Guyer on 03 Oct, 2010 08:04 AM

    Marc Guyer's Avatar

    That is exactly correct.

  2. Marcela Poffald closed this discussion on 11 Apr, 2018 06:13 PM.

Discussions are closed to public comments.
If you need help with Cheddar please start a new discussion.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac