Skip to main content

Reconciler for YNAB - Reconcile YNAB transactions to reach a target balance

This project has been archived.

The maintainers of this project have marked this project as archived. No new releases are expected.

Project description

reconciler-for-ynab

pre-commit.ci status

Reconcile for YNAB - Reconcile YNAB transactions from the CLI

What This Does

When YNAB imports your transactions and balances in sync, reconciliation is a simple one-click process. But sometimes there’s a mismatch, and hunting it down is tedious. I was frustrated with going line-by-line through records to find which transactions should be cleared and reconciled, so I wrote this tool. It streamlines the process by finding which transactions should be reconciled to match a target balance. It will either output the transactions to reconcile, or reconcile them automatically through the YNAB API.

Suppose I want to automatically reconcile my credit card ending in 1234 to $1,471.32. I can do that as follows:

$ reconciler-for-ynab --reconcile --account-name-regex 'credit.+1234' --target 1471.32
** Refreshing SQLite DB **
Fetching budget data...
Budget Data: 100%|████████████████████████████████████████| 10/10 [00:00<00:00, 52.24it/s]
Done
Inserting budget data...
Payees: 100%|█████████████████████████████████████████████| 7/7 [00:00<00:00, 2252.93it/s]
Transactions: 100%|████████████████████████████████████| 14/14 [00:00<00:00, 10605.07it/s]
Done
** Done **
Testing combinations: 100%|██████████████████████████| 32/32 [00:00<00:00, 1065220.06it/s]
Match found:
*      $3.04 - Starbucks
*     $45.14 - Caffe Panna
Reconciling: 100%|██████████████████████████████████████████| 2/2 [00:00<00:00, 11.76it/s]
Done

Installation

$ pip install reconciler-for-ynab

Usage

Token

Provision a YNAB Personal Access Token and save it as an environment variable.

$ export YNAB_PERSONAL_ACCESS_TOKEN="..."

Quickstart

Run the tool from the terminal to print out the transactions:

$ reconciler-for-ynab --account-name-regex 1234 --target 500.30

Run it again with --reconcile to reconcile the account.

$ reconciler-for-ynab --account-name-regex 1234 --target 500.30 --reconcile

All Options

$ reconcile-for-ynab --help
usage: reconciler-for-ynab [-h] --account-name-regex ACCOUNT_NAME_REGEX --target TARGET
                           [--reconcile] [--sqlite-export-for-ynab-db SQLITE_EXPORT_FOR_YNAB_DB]
                           [--sqlite-export-for-ynab-full-refresh] [--version]

options:
  -h, --help            show this help message and exit
  --account-name-regex ACCOUNT_NAME_REGEX
                        Regex to match account name (must match exactly one account)
  --target TARGET       Target balance to match towards for reconciliation
  --reconcile           Whether to actually perform the reconciliation - if not set, just shows
                        the transcations that would be reconciled
  --sqlite-export-for-ynab-db SQLITE_EXPORT_FOR_YNAB_DB
                        Path to sqlite-export-for-ynab SQLite DB file (respects sqlite-export-for-
                        ynab configuration)
  --sqlite-export-for-ynab-full-refresh
                        Whether to do a full refresh of the YNAB data - if not set, only does an
                        incremental refresh
  --version             show program's version number and exit

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

reconciler_for_ynab-0.0.3.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

reconciler_for_ynab-0.0.3-py2.py3-none-any.whl (10.4 kB view details)

Uploaded Python 2Python 3

File details

Details for the file reconciler_for_ynab-0.0.3.tar.gz.

File metadata

  • Download URL: reconciler_for_ynab-0.0.3.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.12

File hashes

Hashes for reconciler_for_ynab-0.0.3.tar.gz
Algorithm Hash digest
SHA256 57957119be7fb38af0abbb47716415f1f870834417aa18c2333e588edb6debc1
MD5 5fa413ab20d36aa14ff1a9984b14b4ed
BLAKE2b-256 5302bcfe79dc414d04a979bc385de7b44c6546de6aac057db33dcddfb9053207

See more details on using hashes here.

File details

Details for the file reconciler_for_ynab-0.0.3-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for reconciler_for_ynab-0.0.3-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 37a1d1be802badcb85675b4a1f58b8921a02227b6ecdb30cdf7c2805ff1a6153
MD5 1003060cc5a939d48b6c74692be4f02d
BLAKE2b-256 50bf41a41cbc3b0971036f806c4bf92540a8c931be3e40fbfc3862baaa01a6b0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page