Let an AI agent prepare your Stripe dispute responses
How an AI agent can catch each Stripe dispute, gather the evidence that wins it and draft the response before the deadline, while you keep the final submit.
A Stripe dispute is a small emergency with a deadline. The money is pulled from your balance the day it opens, a fee comes with it, and you have a limited time to answer with evidence. For a small team, the hard part isn't writing the response. It's noticing the dispute in time, then digging through payments, logs and old emails to prove the customer got what they paid for.
That digging is exactly the work an AI agent is good at. This guide shows how to let an agent catch every dispute, decide which ones are worth fighting, and prepare the evidence, while the submit button stays yours.
#What happens when a customer disputes a Stripe charge?
When a cardholder asks their bank to reverse a payment, Stripe opens a dispute and sends a charge.dispute.created event. From that moment:
- The disputed amount and a dispute fee leave your balance. You get the amount back only if you win.
- A deadline starts. The card network sets it, and it is often only a week or two away. Stripe gives the exact time in the dispute's
evidence_details.due_by. - You choose: counter or accept. Countering means sending evidence; accepting closes the dispute in the customer's favor.
- Evidence goes in once. You can save evidence on the dispute as you go, but once you submit, it is sent to the bank and can't be changed.
- The bank decides. That can take weeks to a couple of months, and Stripe sends
charge.dispute.closedwith the result.
Some networks send an inquiry first, shown with a warning_needs_response status, before any money moves. Answering an inquiry well can stop it from becoming a full dispute.
#Which disputes are worth fighting?
Not all of them. The dispute's reason tells you what the bank needs to see, and whether you have it:
| Reason | What usually wins it | Fight it when |
|---|---|---|
fraudulent | Proof the cardholder used the product: logins, usage after the payment, IP addresses, past undisputed payments | The account was used normally after paying |
product_not_received | Proof of delivery or of access for digital goods | Your logs show they logged in and used it |
subscription_canceled | Your cancellation policy, how it was shown, and no cancellation request before the charge | They never asked to cancel |
credit_not_processed | Proof no refund was due, or that it was already sent | You never promised one |
duplicate | Proof the two charges were for two different things | They really were two purchases |
product_unacceptable | What was promised, what was delivered, your refund policy, your replies to them | You tried to help and they didn't answer |
unrecognized | A clear receipt and your statement descriptor | The customer simply forgot the name on their statement |
And sometimes the honest answer is to accept. If your own logs show the customer asked for a refund and nobody replied, the evidence won't save you, and fighting only adds work. A good agent says so.
For Visa fraud disputes there is an extra route: Visa's Compelling Evidence 3.0 rules let you point to earlier undisputed payments from the same customer that share details such as the IP address or device. If your logs keep those details, an agent can find the matching payments in seconds.
#What can an agent do, and what stays with you?
Draw the line at the submit button.
The agent does:
- Notice each new dispute within seconds, and read it in full from Stripe.
- Work out the deadline in your time zone and remind you before it.
- Pull the facts: the charge, the customer, their subscription, their invoices, their logins and usage from your database, their emails to support.
- Judge the reason code against what it found, and say "fight" or "accept" with why.
- Draft the evidence: a short, dated timeline and the text for each evidence field, with the files it would attach.
You do:
- Read the draft and the recommendation.
- Submit, accept, or refund.
Submitting evidence moves money and can't be undone, which is exactly the kind of step that should wait for a person. Everything before it is reading and preparing, and the agent should do all of it without asking.
#How do you wire it up?
Four pieces, and none of them involves checking Stripe every few minutes.
- An event, not a schedule. Add a webhook endpoint in Stripe for
charge.dispute.created(andcharge.dispute.updatedif you want status changes) pointing at the address that starts your agent. Stripe retries a delivery until it gets an answer, so the receiver should treat a retry of the same event id as one event, or your agent will start twice. - Don't trust the payload. Anyone who learns the address can post to it. The agent should take only the dispute id from what was posted, then fetch the dispute from Stripe's API with its own key before doing anything.
- A restricted key. Create a Stripe restricted key with read access to charges, customers, disputes, invoices and subscriptions. Add write access to disputes only if you want the agent to submit for you after your yes. Never give an agent your full secret key; it can refund and cancel everything.
- Read access to your own data. Login history, usage, support emails. That's where the winning evidence lives, and Stripe doesn't have it.
#What should the evidence look like?
Banks read many of these a day. Short and factual wins:
- A dated timeline at the top. "Nov 2: paid $49 for the annual plan from IP 203.0.113.7. Nov 2 to 19: 34 logins, 212 exports. Nov 20: dispute opened as 'product not received'."
- Each claim backed by a document. A receipt, a screenshot of the usage page, the terms the customer accepted at checkout, the email where they thanked you.
- Matched to the reason code. A
subscription_canceledresponse that talks about fraud misses the point. Answer the question the bank asked. - No emotion, no blame. "The customer is lying" loses. "The account was used daily until the day of the dispute" wins.
An agent is good at this format because it's mechanical: read the logs, sort by date, quote the numbers.
#How do you prevent the next one?
The cheapest dispute is the one that never opens. An agent watching payments can help here too:
- Act on early fraud warnings. Stripe sends
radar.early_fraud_warning.createdwhen a card network flags a charge as likely fraud. Refunding it usually costs less than the dispute it prevents. - Fix your statement descriptor. If customers don't recognize the name on their bank statement,
unrecognizeddisputes follow. Use the name they know. - Make cancelling easy. A customer who can't find the cancel button calls their bank instead.
- Answer "what is this charge?" emails fast. A support message that mentions a dispute, a chargeback or an unknown charge should reach a person within the hour, not the next morning.
Ask the agent for a monthly note: disputes opened, won and lost, by reason. Patterns show up quickly, like one plan that gets cancelled-but-charged complaints, or one country with most of the fraud.
#In Relais
In Relais this is a routine that starts "When a webhook arrives": you give its address to Stripe for dispute events, a retry of the same Stripe event starts one run, and the run gets what Stripe posted as data, never as instructions. The agent then reads the dispute from Stripe's API with the restricted key you gave it in the Vault, plus your database and support history through the tools you gave it; reading runs without asking, and a command that would print or copy a key is refused. It writes the evidence draft in its folder and tells you in its conversation, with a notification, what happened and its recommendation. A POST to Stripe counts as money, so submitting waits for your yes: you answer "submit it" in its conversation, or approve the card it shows. It can also set itself a follow-up two days before the deadline. See routines, the Vault and When should an AI agent ask before it acts?.