Preview a supplier refund of a vendor credit

Shows the refund the commit will post, writing nothing: Dr the bank account / Cr Accounts Payable for the amount, the vendor credit's unapplied balance before and after and its status after (effects). Two forms. A refund that already arrived on an imported money-in bank line sends bank_transaction_id: the refund settles that line (no new line), and its account, amount and date are the line's, so payment_account_id, amount and payment_date may be omitted (sent, they must equal the line's). Without bank_transaction_id, payment_account_id, amount and payment_date record the refund on a new line of an account with no bank feed. Refusals name their code in error.code: bank_transaction_not_found, bank_line_not_incoming, bank_line_excluded, bank_line_not_imported, bank_line_not_open, bank_line_already_booked (409, names the booking and how to undo it), bank_line_account_mismatch, bank_line_amount_mismatch, bank_line_date_mismatch, bank_line_currency_mismatch, refund_exceeds_vendor_credit (a line settles one vendor credit, in full), period_locked (a closed period; a filed VAT period does not refuse, the refund carries no VAT), payment_account_unavailable, payment_account_sync_in_progress (409), bank_line_refunds_unavailable. A line dated before the vendor credit is accepted: the credit keeps its own date. Requires Idempotency-Key: send the same key on the commit with the returned confirmation_token. Requires the vendor-credits:action OAuth scope with update_vendor_credits and update_bank_accounts.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required
Body Params

Proposed values used to preview a supplier refund of a vendor credit without persisting changes.

string | null

An imported money-in line the refund settles; omit to record a new line.

uuid | null

With bank_transaction_id: optional, must be the line's account.

number | null

With bank_transaction_id: optional, must equal the line amount.

date | null

With bank_transaction_id: optional, must be the line date.

string | null
string | null
exchange_rate
object
Headers
string
required
length ≤ 191

Required operation-specific request key. This requirement does not imply durable public API response replay.

Responses

Language
Credentials
OAuth2
Missing 1 required scope
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
*/*