Authorize.net: How to retry failed ARB transactions?

291 views Asked by At

Is there a good way to retry failed subscription payments? Sometimes our customers will fail a payment but then have money the next day, so we just want to retry the payment instead of having them update their card. Some things we've tried:

  • Foolishly signed up for "Automatic Retry" thinking it would automatically retry, but it only retries after the customer updates their card.

  • In order for Automatic Retry to kick in, the subscription needs to change from Suspended to Active which has to be done manually according to support. There's really no way to do this through the API?

Our last resort: On any failed subscription, cancel the subscription and re-create it from the profile, starting on the date we want to retry the payment. Any downsides to this I'm not considering?

2

There are 2 answers

1
John Conde On

There is no way to automatically retry a failed subscription payment through their API. That thread is a few years old but no new endpoints were added since then to enable this functionality.

On any failed subscription, cancel the subscription and re-create it from the profile, starting on the date we want to retry the payment. Any downsides to this I'm not considering?

  1. You will incur transaction fees for retrying even though the chance for success is low.

  2. Make sure you control all notifications. If your user gets emails telling them they're making unexpected payments or setting up new subscriptions you run the risk of chargebacks which could cause you to lose your ability to accept credit cards.

1
Clone On

I know the question is old, but we just figured out how to retry failed subscription transactions.

When an ARB transaction fails, subscription will be suspended. You need to reactivate it in order for Auto retry to make a new attempt.

TL;DR: You can use ARBUpdateSubscriptionRequest to set some new property (I tried with startDate and zip).

In your merchant interface, under Account/Settings/Webhooks you can add a webhook for net.authorize.customer.subscription.suspended event (from tests, they also send failed event, and all of them repeat a couple of times, but, suspended should be sufficient).

Selecting webhook event

You can make separate endpoint for this specific event, or read eventType property from received data to determine if it's the event you want to handle. In received payload there is id property that has the subscription id you can use to update it.

Notification payload

Example JSON that should be sufficient to reactivate suspended subscription is as follows:

{
    "ARBUpdateSubscriptionRequest": {
        "merchantAuthentication": {
            "name": "43ad654nt8",
            "transactionKey": "3F3mEh78L3DXt"
        },
        "subscriptionId": "9086978",
        "subscription": {
            "paymentSchedule": {
                "startDate": "2024-02-08"
            }
        }
    }
}

For detailed information about the request and other parameters here's the API reference:

Update a Subscription