Daily Braintree declined-payment recovery digest to Slack
Every weekday at 8am, your billing team gets a Slack rundown of yesterday's failed Braintree charges, the revenue at risk, and who to chase first.
Every weekday at 8am, run a declined-payment recovery digest so our billing team can chase failed Braintree charges the same morning. This runs on a schedule (cron), Monday through Friday at 8am.
Start with Braintree Search Transactions to pull every transaction created in the last 24 hours whose status is a failure: processor declined, gateway rejected, failed, or authorization expired. Skip anything in test mode, and skip any charge that has already been recovered (for example, a later successful charge to the same customer for the same amount or order). For each qualifying transaction, read the amount, currency, status, and the specific decline or rejection reason.
For each remaining failed transaction, use Braintree Search Customers to look up the customer by their ID or email and pull their name and email address so the billing team knows exactly who to contact. If a customer cannot be matched, still include the charge and note that contact details are missing.
Then build the digest. Total up the revenue at risk across all failed charges (amounts are decimal strings in each transaction's currency, so keep currencies separate if there is more than one). List each affected customer with the amount, the specific decline reason, and a short suggested outreach note tailored to that reason (for example, an expired card reads differently from an insufficient-funds decline). Order the list so the largest recoverable amounts come first.
Post the finished digest to our billing channel with Slack, Send a Message. Lead with the total revenue at risk and the number of affected customers, then the prioritized customer list with amounts, decline reasons, and the suggested notes. Use clear Slack formatting so it is easy to skim on a phone.
If there were no qualifying declined payments in the last 24 hours, post a brief all-clear to the same channel (for example, "No declined Braintree payments in the last 24 hours") instead of staying silent, so the team knows the check ran.
Additional information
What does this prompt do?
- Each weekday morning, gathers every Braintree payment that was declined, rejected, failed, or expired in the last 24 hours.
- Adds each customer's name and email so your team knows exactly who to reach out to.
- Totals the revenue at risk and ranks customers by the biggest recoverable amounts first.
- Posts a clean digest to your billing Slack channel with a suggested outreach note for each customer, or a quick all-clear when there were no failures.
What do I need to use this?
- A Braintree account with permission to view transactions and customers.
- A Slack workspace with a channel for your billing team.
- The name of the Slack channel where the digest should be posted.
How can I customize it?
- Change the schedule, for example run it seven days a week or later in the morning.
- Choose which Slack channel receives the digest.
- Adjust which failure types count, or set a minimum amount so only larger declines are flagged.
Frequently asked questions
Which failed payments does it include?
Will it flag test transactions?
What happens on a day with no failed payments?
Do I need to write the outreach messages myself?
Can I run this on weekends too?
Related templates
Stop letting failed payments slip through the cracks.
Start every morning with a clear list of the declined charges worth chasing and exactly who to contact.