Insert transactions

Use this endpoint to insert many transactions at once.

post
Insert transactions

https://dev.lunchmoney.app/v1/transactions
Bulk-insert transactions
Request
Response
Request
Query Parameters
transactions
required
array
List of transactions to insert (see below)
apply_rules
optional
boolean
If true, will apply account’s existing rules to the inserted transactions. Defaults to false.
check_for_recurring
optional
boolean
If true, will check new transactions for occurrences of new monthly expenses. Defaults to false.
debit_as_negative
optional
boolean
If true, will assume negative amount values denote expenses and positive amount values denote credits. Defaults to false.
Response
200: OK
Upon success, IDs of inserted transactions will be returned in an array.
{
ids: [54, 55, 56, 57]
}
404: Not Found
An array of errors will be returned denoting reason why parameters were deemed invalid.
{ error:
[ 'Transaction 0 is missing date.',
'Transaction 0 is missing amount.',
'Transaction 1 status must be either cleared or uncleared: null' ] }
Insert Transaction object
Insert Transaction object

Insert Transaction object

Key

Type

Description

date

string

Must be in ISO 8601 format (YYYY-MM-DD).

Required.

amount

number | string

Numeric value of amount. i.e. $4.25 should be denoted as 4.25.

Required.

category_id

number

Unique identifier for associated category_id. Category must be associated with the same account and must not be a category group.

payee

string

Max 140 characters

currency

string

Three-letter lowercase currency code must exist in our database. Defaults to user account's primary currency.

asset_id

number

Unique identifier for associated asset (manually-managed account). Asset must be associated with the same account.

recurring_id

number

Unique identifier for associated recurring expense. Recurring expense must be associated with the same account.

notes

string

Max 350 characters

status

string

Must be either cleared or uncleared. If recurring_id is provided, the status will automatically be set to recurring or recurring_suggested depending on the type of recurring_id.

Defaults to uncleared.

external_id

string

User-defined external ID for transaction. Max 75 characters. External IDs must be unique within the same asset_id.

tags

Array of numbers and/or strings

Passing in a number will attempt to match by ID. If no matching tag ID is found, an error will be thrown.

Passing in a string will attempt to match by string. If no matching tag name is found, a new tag will be created.