Because OpenSettle is non-custodial, the funds being refunded already live in your wallet — not ours. Every refund is a transaction broadcast from the merchant settlement wallet back to the customer wallet of record. We orchestrate, sign-via-your-key (or hand off to your signer), track, and emit webhooks; we do not move money on your behalf without an authorized signature.
const refund = await os.refunds.create({
payment: "pay_9fX0a2E1",
amount: 49.00, // omit for full refund
reason: "requested_by_customer",
metadata: { ticket: "ZD-7184" },
});
// Returns the unsigned tx for your signer, or broadcasts immediately
// if the wallet is registered with our co-signer service.
console.log(refund.status); // "pending_signature" | "broadcast"A payment can have multiple refunds, summing up to (but not exceeding) the original amount minus our fee. The original fee stays paid — fees are non-refundable, matching how every card processor handles partial chargebacks. If you need to refund the fee too, use include_fee: true; we will credit it on your next monthly invoice.
From a payment row in the dashboard, click Refund, choose an amount, and confirm with your connected wallet. The CLI is equivalent for scripted workflows:
$ opensettle refunds create pay_9fX0a2E1 --amount 49.00
✓ Refund rf_7Hq2XZpL prepared (49.00 USDC)
→ Awaiting signature in dashboard
✓ Broadcast: 0x4ae1…b9d7
✓ Confirmed in 3.8srefund.created — refund object created; awaiting signature.refund.broadcast — signed transaction submitted to the chain. Carries tx_hash.refund.confirmed — required confirmations reached. Customer notified.refund.failed — reverted on-chain or rejected by signer. Inspect last_error.Gas for refund transactions is paid by the merchant wallet — same as any outbound transfer. On EVM chains we estimate a tight upper bound and warn before broadcast if the estimate exceeds 1% of the refund amount (configurable). On Tron, gas is paid as TRX or burned as energy from the staking account; ensure the wallet holds at least 50 TRX of bandwidth for refund operations. Solana and L2 gas are typically below $0.01 and not worth surfacing.