Create a transaction
ynab_create_transactionAdd a transaction to a YNAB account by specifying amount, date, payee, and category. Negative amounts record expenses, positive amounts record income.
Instructions
Create a transaction in an account.
The amount is given in normal currency units (e.g. -12.50 for a 12.50 expense); conversion to milliunits is automatic. Returns the new id.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"account_id": "<account_id>",
"amount": "<amount>"
},
"name": "ynab_create_transaction"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| memo | No | Free-form memo | |
| amount | Yes | Amount in currency units. NEGATIVE for an expense, positive for income. E.g. -12.50 | |
| cleared | No | 'cleared', 'uncleared' or 'reconciled' | uncleared |
| approved | No | Mark as approved | |
| txn_date | No | Date YYYY-MM-DD (default: today) | |
| budget_id | No | Budget id, or 'last-used' | last-used |
| account_id | Yes | Target account (required) | |
| payee_name | No | Payee name (created if it does not exist) | |
| category_id | No | Category to assign |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |