Regoria API docs

Refunds and disputes

Refunds

A refund returns part or all of a payment (its chg_ charge) to the buyer's card:

curl -X POST https://api.sandbox.staging.regoria.com/v1/refunds \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: refund-INV-1001-1" \
  -d '{"order_id": "ord_01HZX5Y3V8N2K7QJ4R9T6B3M1C", "amount_cents": 1000, "reason": "requested_by_customer"}'

Refund states: sending, issued, failed, rejected, unknown (the processor's answer was lost; it is reconciled nightly).

Sales tax is refunded in proportion and reported to the tax authority as a credit; you do nothing. The processing fee of the original sale is not returned to you.

GET /v1/refunds lists refunds (state[], charge_id[], range; charge_public_id[], the older name of charge_id[], is still read); GET /v1/charges and GET /v1/charges/{charge} show every charge with its state, card summary, refunded_cents, its payment_system (how the buyer paid: credit_card, apple_pay, google_pay), its capabilities (refund and void), and the decline code and category when it was declined.

Currency

A refund is always in the currency the buyer was charged in, and amount_cents is in that currency's smallest unit. The buyer gets back the amount they paid, not a newly converted one. The refund leaves your balance in the same currency.

Disputes

A dispute is a chargeback the card network opened against one of your payments. The buyer's bank took the money back pending the outcome. A payment can be charged back more than once (a second partial chargeback, or a new round after a won one); each chargeback is its own dispute.

Field Meaning
source chargeback
provider_case_id the processor's chargeback id, when Regoria received it
status open, evidence_submitted, won, lost, accepted, expired
amount_cents, fee_cents the disputed amount and the dispute fee
reason_code, reason_label the network's reason code and its name ("Merchandise or services not received" for 13.1); the name is null for a code Regoria has no name for
merchant_evidence_due_at when your evidence is due: 3 business days after the dispute opened
evidence_due_at the bank's deadline, the last day evidence can reach the network
over_disputed the payment's open and lost disputes add up to more than the payment; Regoria checks it with the processor

Disputes are read-only in the API (GET /v1/disputes, GET /v1/disputes/{dispute}). Evidence is submitted from the dashboard (Disputes), where you attach the fulfilment proof, the receipt and your correspondence; the evidence you recorded with POST /v1/orders/{order}/fulfil is already there.

Events: dispute.opened when it opens (stop shipping, revoke access: order.access_revoked follows for the order), dispute.closed with the outcome.

Money

The disputed amount and the dispute fee are charged to your balance when the dispute opens; a won dispute returns the amount, not the fee. Both appear as balance transactions (category: "dispute", "dispute_fee", "dispute_reversal") in Balance and payouts.

A refund or a dispute of a sale that already settled in another currency than the buyer paid in: the buyer gets back the amount of the currency they paid in, and your balance is debited in the currency the sale settled in, at the rate that sale settled at (or the promised rate, when fx_bearer on the order is platform). With merchant, the small difference to what the processor finally takes for the refund is added to or taken from your balance when it settles.

Keeping disputes rare