Skip to content

Update a transaction

PUT
/api/v1/money/budgets/{budget_id}/transactions/{transaction_id}
curl --request PUT \
--url https://example.com/api/v1/money/budgets/example/transactions/example \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "account_id": "example", "amount": 1, "category_id": "example", "cleared": true, "date": "example", "notes": "example", "payee": "example" }'

Replace a simple register row with the request fields. If the date names another month, the server moves the row and its note lines to that month. The response returns the saved row. Split, transfer, and foreign-currency rows are not supported. Route: /api/v1/money/budgets/{budget_id}/transactions/{transaction_id}. Inputs: budget_id, transaction_id. Do not automatically replay this operation after an uncertain result.

budget_id
required
string

Budget ID

transaction_id
required
string

Transaction ID

Media typeapplication/json

Create or replace a simple transaction (one account, one category).

object
account_id
required

Account ID (in the budget currency).

string
amount
required

Minor units: outflow negative, inflow positive.

integer format: int64
category_id
required

Expense, income or opening-balance category ID.

string
cleared

Cleared flag (#cleared); defaults to false.

boolean | null
date
required

Date YYYY-MM-DD.

string
notes

Separate notes; omitted on an edit to preserve existing notes (#1130).

string | null
payee
required

Payee text; transaction Notes use their own field (#1130).

string
Examplegenerated
{
"account_id": "example",
"amount": 1,
"category_id": "example",
"cleared": true,
"date": "example",
"notes": "example",
"payee": "example"
}

The edited register row

Media typeapplication/json

One register row.

object
account_id
required

Account whose register shows this row.

string
account_name
required

Account name.

string
amount
required

Amount in currency minor units, as seen by account_id.

integer format: int64
budget_amount
required

Amount in budget minor units.

integer format: int64
category_id
required

Category ID (a Split or Transfer marker for those rows).

string
category_name
required

Category name.

string
cleared
required

This Account’s cleared mark; explicit source state overrides legacy #cleared tags and remains independent of reconciled state (#1130).

boolean
currency
required

Currency of amount.

string
date
required

Date YYYY-MM-DD.

string
editable
required

True when this build can edit the row (simple, unreconciled rows only; #462, #1130).

boolean
id
required

Transaction ID (the row’s ^block-id).

string
kind
required

simple, split, transfer or card_payment.

string
memo
required

Payee text without tag tokens, for display next to tags.

string
notes
required

Separate notes, with original whitespace (#1130).

string
payee
required

Payee text exactly as written (with its tags); Notes are separate (#1130).

string
reconciled
required

True when this source row was reconciled (#1130).

boolean
scale
required

Decimal places of currency.

integer format: int32
source_rows
required

Original source rows, retained without extra postings (#1130).

Array<object>

Typed source evidence for split, transfer and Tracking rows (#1130). The API crate owns its schema; the pure Money crate has no HTTP dependency. Evidence records never create additional postings.

object
account_id
required

Stable Money Account identity.

string
amount
required

Original amount in budget minor units.

integer format: int64
category_id

Stable Money Category identity, when the source had one.

string | null
cleared
required

Independent source cleared mark.

boolean
date
required

Original date in YYYY-MM-DD form.

string
id
required

Original export identity.

string
notes
required

Original Notes, including whitespace.

string
payee
required

Original Payee, flattened for a Markdown row.

string
reconciled
required

Independent source reconciled mark.

boolean
splits
required

Split legs.

Array<object>

One split leg of a transaction.

object
amount
required

Amount in budget minor units.

integer format: int64
category_id
required

Category ID.

string
category_name
required

Category name.

string
tags
required

Inline calternal tags in the Payee, in order, without #cleared (the cleared flag has its own column). Parsed by the Notes tag grammar so a Money tag is the same tag everywhere (DESIGN §48: ordinary tags).

Array<string>
transfer_account_id

The other Account of a transfer or Card payment.

string | null
transfer_category_id

Category posted by a transfer between on-budget and off-budget accounts.

string | null
transfer_category_name

Display name for transfer_category_id.

string | null
Examplegenerated
{
"account_id": "example",
"account_name": "example",
"amount": 1,
"budget_amount": 1,
"category_id": "example",
"category_name": "example",
"cleared": true,
"currency": "example",
"date": "example",
"editable": true,
"id": "example",
"kind": "example",
"memo": "example",
"notes": "example",
"payee": "example",
"reconciled": true,
"scale": 1,
"source_rows": [
{
"account_id": "example",
"amount": 1,
"category_id": "example",
"cleared": true,
"date": "example",
"id": "example",
"notes": "example",
"payee": "example",
"reconciled": true
}
],
"splits": [
{
"amount": 1,
"category_id": "example",
"category_name": "example"
}
],
"tags": [
"example"
],
"transfer_account_id": "example",
"transfer_category_id": "example",
"transfer_category_name": "example"
}
Media typeapplication/json

The standard API error response: { "error": { ... } }.

object
error
required

Error details.

object
code
required

Stable machine-readable code.

string
Allowed values: bad_request unauthorized forbidden not_found conflict name_conflict_case name_too_long push_endpoint_rejected too_many_requests internal service_unavailable
details
One of:

Optional field or operation details.

object
key
additional properties
string
message
required

Safe text for logs or a user-facing error message.

string
Example
{
"error": {
"code": "bad_request"
}
}
Media typeapplication/json

The standard API error response: { "error": { ... } }.

object
error
required

Error details.

object
code
required

Stable machine-readable code.

string
Allowed values: bad_request unauthorized forbidden not_found conflict name_conflict_case name_too_long push_endpoint_rejected too_many_requests internal service_unavailable
details
One of:

Optional field or operation details.

object
key
additional properties
string
message
required

Safe text for logs or a user-facing error message.

string
Example
{
"error": {
"code": "bad_request"
}
}
Media typeapplication/json

The standard API error response: { "error": { ... } }.

object
error
required

Error details.

object
code
required

Stable machine-readable code.

string
Allowed values: bad_request unauthorized forbidden not_found conflict name_conflict_case name_too_long push_endpoint_rejected too_many_requests internal service_unavailable
details
One of:

Optional field or operation details.

object
key
additional properties
string
message
required

Safe text for logs or a user-facing error message.

string
Example
{
"error": {
"code": "bad_request"
}
}

Not yet supported (split, transfer, foreign currency)

Media typeapplication/json

The standard API error response: { "error": { ... } }.

object
error
required

Error details.

object
code
required

Stable machine-readable code.

string
Allowed values: bad_request unauthorized forbidden not_found conflict name_conflict_case name_too_long push_endpoint_rejected too_many_requests internal service_unavailable
details
One of:

Optional field or operation details.

object
key
additional properties
string
message
required

Safe text for logs or a user-facing error message.

string
Example
{
"error": {
"code": "bad_request"
}
}