Correct a recorded expense
Corrects one line — the day, the supplier, the amount, the category, the payment channel, the note, the category’s extra fields or a journey’s distance — while it may still be edited: a line in no nota spese, or in one that is draft or rejected. A line inside a report that has already left is refused, and can be corrected only once that report comes back. Name only what changes; null clears a field that may be empty. The caller corrects their own lines, and whoever manages the company’s expenses anybody’s. If the line sits in an open report, that report’s totals follow it in the same call. ⚠ A CAR JOURNEY (km) IS PRICED BY THE SERVER: give distance_km and never an amount or a currency — it is re-priced at the rate frozen onto the line when it was filed. ⚠ metadata REPLACES the extra fields as a whole: send every field that should stay (spese_get_expense with detailed shows them). The kind of a line cannot change.
Request
- Base URL: https://api.custodo.ai
- URL: https://api.custodo.ai/api/v1/rest/spese/expenses/{id}
- Auth: HTTP bearer
Path parameters
The expense id, from spese_list_expenses or spese_get_expense.
Headers
The organisation to act in. An API key is bound to exactly one, so this is optional for a key and must match the one it was minted for.
Request body
Response
Done. data is the tool’s own answer.
Changes
No recorded changes to this operation across all 1 revision of this API.