Skip to main content

Update Expense

PUT PATCH /public/action/expenses/update

Updates an existing expense, identified by id in the request body. Use PATCH to change a few fields (partial merge) or PUT to replace the whole record.

Authentication: X-API-KEY header (see Authentication).

PUT is a full replace

With PUT, fields you omit are overwritten. For a few fields, use PATCH instead. id is required for both; accountId is forced to your workspace.

Request body

The full Expense object. Key fields:

FieldTypeDescription
idstringRequired. Id of the expense to update.
amountnumberExpense amount.
currencystringCurrency code.
taxRatenumberTax rate.
taxInclusivebooleanWhether amount includes tax.
categorystringExpense category.
vendorIdstringVendor id.
clientIdstringClient to bill (optional).
projectIdstringRelated project (optional).
billNostringBill / receipt number.
paidbooleanWhether the expense is paid.
paidDate, dueDatedatePaid / due dates.
reimbursablebooleanBillable / reimbursable.
markupPercentnumberMarkup applied when billed to a client.
description, notesstringText fields.

Request (PATCH — partial)

curl -X PATCH https://api.withmoxie.com/public/action/expenses/update \
-H "X-API-KEY: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"id": "66b0f7d4c3a9e40012ab7722",
"paid": true,
"paidDate": "2026-07-10"
}'

Response

Returns the full updated Expense object.

{
"id": "66b0f7d4c3a9e40012ab7722",
"accountId": 10016,
"amount": 120.00,
"currency": "EUR",
"category": "Software",
"vendor": "Adobe",
"description": "Stock photos",
"paid": true,
"paidDate": "2026-07-10",
"reimbursable": true
}

Errors

StatusMeaning
412 Precondition Failedid was missing from the body.
404 / Not FoundNo expense with that id exists in your workspace.