The problem
When your agent callsstripe.charge_customer and the network drops before a response arrives, it doesn’t know whether the charge landed. Retrying blindly risks a duplicate charge. Not retrying risks an incomplete transaction.
Solution: write-once-checkable reconciliation
Classifystripe.charge_customer as write-once-checkable. Invoke will:
- Write a commit record before the charge attempt
- If the outcome is unknown, call
POST /outcomes/reconcilewith live Stripe state - If the charge already succeeded, return
reconciledand block the retry - If the charge didn’t succeed, allow the retry safely
Verify identity before refunds
Before issuing a refund, usePOST /state/verify to confirm the customer identity hasn’t drifted since the agent resolved it:
customer_id has changed, Invoke returns replan_required before the refund executes.
Next steps
- Reconciliation — how unknown outcomes are resolved
- Tool Safety Classes — how to classify billing tools
- POST /outcomes/reconcile — full API reference