Record document payment
record_document_paymentRecord a payment against any document, in either direction. A money-in document (invoice, recurring invoice, quote, debit note) records the payment as an income; a money-out document (bill, purchase order, GRN, credit note) is settled by recording an expense whose accountid is the document's id — the tool dispatches on the document's direction, so pass the document id and the payment details either way.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Document id to record the payment against — a money-in document (invoice / recurring invoice / quote / debit note) or a money-out document (bill / purchase order / GRN / credit note). On update, the payment id. | |
| date | No | Date the payment was received (ISO 8601). | |
| name | No | Label for this payment (e.g. "Deposit", "Final payment"). | |
| notes | No | Free-text notes on the payment. | |
| amount | No | Payment amount in the payment's currency. | |
| method | No | Payment method as free text (e.g. "cash", "card", "eft") — no fixed set. | |
| payment | No | Bank/ledger account id the money moved through — received into (money-in) or paid from (money-out) (see list_accounts). | |
| category | No | Income category for the payment; defaults to Sales when omitted. | |
| currency | No | ISO 4217 currency code (e.g. "ZAR", "USD"). Defaults to the business currency. | |
| responseid | No | Internal: correlation id used to return the updated entity to the frontend; omit. | |
| exchangerate | No | Manual FX rate to the business base currency; omit to use the stored/auto rate. |