Triage failed Recurly payments by how much revenue is at risk
When a payment fails in Recurly, work out what is actually at stake and route it to the right Slack channel with a named owner and a follow up task.
When Recurly sends a failed_payment_notification webhook, triage the failed payment instead of dumping a raw alert into Slack. Use the account code and the transaction id from the webhook payload as the starting point for everything below.
First, use Recurly Get Transaction to pull the decline details for the failed transaction: the amount, the currency, the decline reason or error code, the payment method, and whether it was a recurring charge. Then build a picture of the account. Use Recurly Get Account Balance to read the current outstanding balance and whether the account is already past due. Use Recurly List Account Subscriptions to total the active recurring revenue at risk, normalizing each active subscription to a monthly figure so that plans billed annually and monthly are comparable. Use Recurly List Account Invoices to check whether this is a repeat failure for the same customer, counting past due or previously failed invoices in the last 90 days.
Next, look the customer up in HubSpot using Search Contacts, matching on the email address from the Recurly account. Read the contact owner and the lifecycle stage. If the contact has an owner, use HubSpot Get Owner to resolve that owner id into a real name and email, so the Slack message can name a person rather than an opaque id. If no contact matches, carry on anyway and state clearly in the alert that the customer was not found in the CRM.
Decide a risk tier before writing anything. Treat the failure as high risk if any one of these is true: the monthly recurring revenue at risk is at or above $500, the account is already past due, or this is a repeat failure for the same customer within the last 90 days. Otherwise treat it as a low risk one off decline. Keep that threshold in one obvious place near the top of the workflow so it is easy to change.
Post the result with Slack Bot Send a Message, and lead every message with the tier so it is readable at a glance. High risk failures go to a dedicated revenue risk channel and must name the HubSpot owner and their lifecycle stage, the monthly recurring revenue at risk, the decline reason, whether the account is past due, and how many times this customer has failed before. Low risk one off declines go to a quieter billing channel as a single short line: customer, amount, decline reason. Use Slack formatting, where a single asterisk means bold, not standard Markdown.
For high risk failures only, also create a HubSpot Task using Create Task, assigned to the contact owner you resolved, due two business days out. Give it a subject naming the customer and the amount at risk, and a body summarizing the decline reason, the recurring revenue at risk, the past due status and the failure history. Associate the task with the contact so it shows up on the record. If the contact has no owner, still create the task and leave it unassigned rather than skipping it. The point is that recovery on a high value account is tracked as real work instead of scrolling away in a channel.
Keep it to one Slack message per failed payment event, and never post the same failure to both channels. If any Recurly or HubSpot lookup fails, still post the alert with whatever detail is available and note what could not be retrieved, because a partial alert is far better than silence on a failed payment.
Example output
What does this prompt do?
- Picks up every failed payment in Recurly the moment it happens, instead of waiting for someone to check the billing dashboard.
- Works out what is really at stake: the decline reason, how much recurring revenue the account represents, whether they are already behind on payments, and whether this customer has failed before.
- Looks the customer up in your CRM so the alert carries a real owner and lifecycle stage rather than an anonymous account code.
- Posts a Slack alert that leads with a risk tier, sending high value or repeat failures to a revenue risk channel and small one off declines to a quieter billing channel.
- For high value accounts, creates a follow up task for the record owner with a due date, so recovery is tracked as work instead of scrolling away in a channel.
What do I need to use this?
- A Recurly account with admin access, so you can point payment failure notifications at this workflow.
- A HubSpot login where your customers exist as contacts with owners assigned.
- A Slack workspace, plus two channels: one for revenue risk and one for routine billing noise.
- A rough idea of what counts as a high value account for you, in monthly recurring revenue.
How can I customize it?
- Change the threshold that separates a high value account from a routine decline, in monthly recurring revenue.
- Swap the two Slack channels, or point both at the same channel while you tune the tiering.
- Adjust how long the owner gets before the recovery task is due, or send every task to one shared queue instead of the record owner.
FAQs
Will this fire for every retry attempt?
What counts as a repeat failure?
Does this work if we do not use HubSpot?
Do we need a developer to set this up?
What happens to accounts that are not in our CRM?
Related templates
When someone leaves, we check which shared passwords they used in their final months and post a ranked rotation list to your security channel.
Every Monday, check every S3 bucket for public exposure, missing encryption and weak backup settings, then get the risks ranked in Slack.
Twice every weekday, the conversations from your social inbox land on the right HubSpot contact timelines, with a Slack recap for sales.
Every weekday at 7am, sign in to the tender portals you track, filter new notices against your bid criteria, and open a deal for the ones worth chasing.
Every morning, find the addresses that hard bounced or filed a spam complaint, update the matching HubSpot contacts, and post a short Slack recap.
Every weekday at 4pm, spot the threads that went quiet, stage a ready-to-send nudge in your mailbox, and get a ranked Slack recap.
Stop letting failed payments scroll past in Slack.
Every decline arrives ranked by revenue at risk, with an owner named and a recovery task already on their list.