E-commerce

Refunds at machine speed,
goodwill within limits

Retail teams run refund, pricing, and inventory agents through govern.sh so the easy 90% of cases resolve in seconds — and the expensive edge cases pause for a human before a dollar moves.

The problem

Where autonomy breaks down today

01

Refund authority is all or nothing

An agent with your Stripe key can refund $4 or $4,000 with the same call. Without runtime limits, one bad parse of an angry email becomes a five-figure mistake.

02

Peak season breaks manual review

The review queue that works in March collapses in November. Teams either slow refunds to a crawl or wave everything through — both cost real money.

03

Chargebacks arrive without evidence

When a customer disputes an automated refund or credit, support has screenshots and log lines — not proof of what the agent did, under which policy, approved by whom.

A day in the life

One refund, fully accounted for

A customer reports a damaged espresso machine on order #58201. refund-agent picks up the ticket and works it to a signed close.

refund-agent
Resolves refund requests end to end for the storefront
01

refund-agent verifies the order

Passport

Acting under its own passport, the agent reads the order history and delivery confirmation. Its credential can read orders and issue refunds — nothing else in your Stripe account.

agent: refund-agent · scope: orders.read, stripe.refund
02

It requests a $412 refund

Policy

payments-guardrail evaluates stripe.refund in 7 ms. The amount is inside the agent's $2,500 daily budget but above the $250 auto-approve line.

stripe.refund · $412.00 · order #58201 · policy hit: >$250
03

The refund holds for human sign-off

Approval

Instead of executing or erroring, the action pauses. Dana on the CX team gets a Slack card with the order, the damage photos, and the agent's reasoning.

require_approval: amount > $250 → queue: cx-leads
04

Dana approves in Slack

Budget

One tap. The refund executes against Stripe, the customer gets their money, and the daily refund budget decrements by $412.

approved_by: dana.k · budget remaining: $1,671 / $2,500
05

The receipt closes the loop

Receipt

A signed receipt — agent, amount, policy verdict, approver — is chained into the audit trail and attached to the ticket. If this refund is ever disputed, the proof is one link away.

rcp_8f2a…c41 · signed & chained · attached to #58201
What govern.sh adds

Autonomy tuned to your margins

Set the auto-approve line where your unit economics say it belongs, and move it seasonally without redeploying a single agent.

Approval thresholds in plain policy

One line — require_approval: amount > $250 — separates instant resolution from human review. Change the number, not the agent.

Daily budgets per agent

Refund and credit agents carry hard daily caps. Runaway loops and prompt injection stop at the budget line, not at your month-end close.

Receipts attached to orders

Every refund, credit, and price change links a signed receipt to the order record — your chargeback response writes itself.

Scales with your traffic

Policy decisions run in single-digit milliseconds, so Black Friday volume changes nothing about how carefully each action is checked.

payments-guardrail.yml
1policy: payments-guardrail
2applies_to: refund-agent
3rules:
4 - action: stripe.refund
5 max_amount: $500
6 require_approval: amount > $250
7 - action: db.write
8 scope: orders.refunds only
9audit: signed_receipt(ed25519)
−74%
Refund handling time, request to resolution
68%
Refunds resolved with zero human touches
0
Over-limit refunds since enforcement went live

Representative outcomes reported by govern.sh customers in e-commerce.

PCI DSS

Cardholder-safe by construction

Agents act through scoped credentials that never expose full payment instrument data, and every action against the payment stack lands in a tamper-evident log — supporting PCI DSS Requirements 7 and 10 on least-privilege access and traceability. Your QSA gets a receipt chain, not a log export to interpret.

We set the auto-approve line at $250 and let refund-agent run through Cyber Week. It closed eleven thousand tickets, and the forty-one that paused for approval were exactly the ones I would have wanted to see.
Marcus Idehen
Director of CX Operations, Fieldstone

Put a verified agent to work in e-commerce.

Mint a passport, attach a policy, and watch the first signed receipt land — free for your first three agents.