Change an expense record
update_expenseChanges an expense record that is already there, by its id from list_expenses: its date or due date, expense account, supplier, amount, property, the people liable for it, or its notes; its expense type never changes. Send only what the person tells you; taxapp works out every total from it. Give only what changes: every parameter left out keeps the value the record has now. Read the record first, and confirm the change with the person before making it. A record sent to Xero keeps its amount and date. Only for an organisation where this connection may add and change records (list_organisations says which). The answer is the changed record as list_expenses shows it.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| clear | No | Optional fields to empty, by parameter name, any of: due_date, property_id, liable_contact_ids, notes. | |
| notes | No | Free text kept with the record, such as the invoice number ("Invoice number: 1234"). | |
| amount | No | The bill's total in NZD. | |
| due_date | No | The New Zealand date the bill is due, yyyy-MM-dd. | |
| contact_id | No | The supplier or payee, from list_contacts. | |
| expense_id | Yes | The expense record's id, from list_expenses. | |
| property_id | No | A rental cost's property, from list_properties. | |
| expense_date | No | The New Zealand date of the bill or cost, yyyy-MM-dd. | |
| organisation_id | No | The id of the organisation to use, from list_organisations. Leave it out when the connection covers only one organisation; it is required when it covers more than one. | |
| expense_account_id | No | The expense account to file it under, from list_expense_accounts. | |
| liable_contact_ids | No | Every contractor or property owner liable for the cost, from list_contacts; replaces the list the record has now. |