Overview
The YNAB Trigger node allows n8n workflows to react to various events from the You Need A Budget (YNAB) API by polling for changes. It is useful for automating tasks based on financial data updates such as new or updated transactions, account balance changes, category balance changes, and scheduled transaction modifications.
Common scenarios include:
- Automatically syncing new or updated transactions to another system.
- Monitoring account or category balances to trigger alerts or reports.
- Reacting to scheduled transaction creations or updates for budgeting automation.
For example, you could use this node to trigger a workflow whenever a new transaction is added in YNAB, filter it by account or category, and then send a notification or update a spreadsheet.
Properties
| Name | Meaning |
|---|---|
| Event | The type of YNAB event to listen for. Options: • Transaction Added (new transaction created) • Transaction Updated (existing transaction changed) • Account Balance Changed • Category Balance Changed • Scheduled Transaction Created • Scheduled Transaction Updated |
| Filters | Filters applicable only when Event is "Transaction Added" or "Transaction Updated": • Account Name or ID: Filter transactions by specific account • Category Name or ID: Filter by category • Payee Name or ID: Filter by payee • Minimum Amount: Only trigger if absolute amount ≥ this value • Transaction Type: Filter by all, uncategorized, or unapproved transactions • Include Transfers: Whether to include transfer transactions |
| Options | Additional options: • Whether Subtransactions Are Included (for splits) — applies to transaction added/updated events • Whether Deleted Are Included — whether to trigger on deleted items too |
Output
The node outputs an array of JSON objects representing the triggered events. Each item corresponds to one event instance with detailed data from YNAB:
- For transaction events, the output includes full transaction details, with amounts converted to currency units (amount divided by 1000), and an
event_typefield indicating if it was "added" or "updated". - If subtransactions are included, each subtransaction is output separately with its parent transaction ID.
- For account balance changes, the output contains account details including previous balance, balance change, current balance, cleared and uncleared balances, all converted to currency units.
- For category balance changes, the output includes category group name, previous balance, balance change, current balance, activity, and budgeted amounts.
- For scheduled transaction events, the output includes scheduled transaction details with amounts converted and an
event_typefield ("created" or "updated").
If binary data were involved (not in this node), it would be summarized here, but this node only outputs JSON data.
Dependencies
- Requires an active connection to the YNAB API using an API key credential configured in n8n.
- Needs the budget ID to access relevant data.
- Uses polling to check for updates, so the node must be set up with appropriate polling intervals.
- Relies on helper methods to fetch accounts, categories, and payees dynamically for filter options.
Troubleshooting
- No triggers firing: Ensure the correct budget ID and API key are configured. Verify that the selected event matches actual changes in YNAB.
- Missing data in output: Check filters; overly restrictive filters may exclude all results. Also, verify if "Include Deleted" or "Include Transfers" options affect results.
- API errors: Could be due to invalid credentials, expired tokens, or network issues. Review error messages logged by the node.
- Duplicate events: The node tracks processed IDs to avoid duplicates, but resetting workflow static data or changing polling intervals might cause repeats.
- Large data sets: The node limits stored processed IDs to 500 to manage memory; very high-frequency changes might require adjusting polling frequency.