Reverse an outcome charge
Reverses a charge by hand. This is the exception path; reversal rules handle the usual cases. Allowed while the charge is pending, disputed or confirmed, and refused with outcome_charge_locked once the reversal horizon has passed. A pending charge’s reservation is released. A confirmed prepaid charge’s credits are restored. A postpaid charge comes off the draft invoice, or appears as a credit on the next invoice if it was already invoiced. A reversal applies to a whole charge; partial reversals aren’t supported.
Authentication
A secret key (rl_sk_test_..., rl_sk_live_...) or a restricted key with limited scopes (rl_rk_test_..., rl_rk_live_...). A restricted key can carry agent: true and an expires_at, and is what a coding agent should hold. Keys end in a checksum so secret scanners can recognize them. People create, roll and revoke keys in the dashboard; GET /v1/api_keys lists them, masked.
Path parameters
The outcome charge ID (oc_...).
Request
Response
rule: a reversal rule fired. dispute: a dispute was decided reverse, by you or by default. api: you called reverse.
reservation_released: the charge was pending, so nothing was billed. credits_restored: prepaid credits came back. accrual_removed: the postpaid charge came off the draft invoice. invoice_credit: the charge was already invoiced, so the next invoice carries a credit.
The rule key, when source is rule.
The signal event, when source is rule.
The request, when source is api.
Who reversed it, when source is api or a person decided a dispute. A rule is named by rule.
invoice_credit only: the invoice carrying the credit, once it exists.