fints2ledger: Download transactions from FinTS into a ledger journal

This is a package candidate release! Here you can preview how this package release will appear once published to the main package index (which can be accomplished via the 'maintain' link below). Please note that once a package has been published to the main package index it cannot be undone! Please consult the package uploading documentation for more information.

[maintain] [Publish]

Please see the README on GitHub at https://github.com/MoritzR/fints2ledger#readme


[Skip to Readme]

Properties

Versions 1.1.0
Change log CHANGELOG.md
Dependencies aeson (>=2.0.3 && <2.0.4), base (>=4.16.4 && <4.16.5), base16-bytestring (>=1.0.2 && <1.0.3), brick (==1.4), bytestring (>=0.11.4 && <0.11.5), cassava (>=0.5.3 && <0.5.4), containers (>=0.6.5 && <0.6.6), cryptohash-md5 (>=0.11.101 && <0.11.102), dates (>=0.2.3.2 && <0.2.4), directory (>=1.3.6 && <1.3.7), filepath (>=1.4.2 && <1.4.3), fints2ledger, generic-lens (>=2.2.2 && <2.2.3), haskeline (>=0.8.2 && <0.8.3), hledger-lib (>=1.27.1 && <1.27.2), lens (==5.1.1), optparse-applicative (>=0.17.1 && <0.17.2), regex-tdfa (>=1.3.2 && <1.3.3), text (>=1.2.5 && <1.2.6), text-format-heavy (==0.1.5.3), time (>=1.11.1 && <1.11.2), transformers (>=0.5.6 && <0.5.7), typed-process (>=0.2.11 && <0.2.12), vector (>=0.12.3 && <0.12.4), vty (==5.37), yaml (>=0.11.11 && <0.11.12) [details]
License MIT
Copyright 2023 Moritz Rumpf
Author Moritz Rumpf
Maintainer moritz.rumpf@gmail.com
Category Finance, Console
Home page https://github.com/MoritzR/fints2ledger#readme
Bug tracker https://github.com/MoritzR/fints2ledger/issues
Source repo head: git clone https://github.com/MoritzR/fints2ledger
Uploaded by mrum at 2023-09-15T16:29:04Z

Modules

Flags

Manual Flags

NameDescriptionDefault
bundle_data_dir

Set the data dir to be relative to the executable for easier bundling

Disabled

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees


Readme for fints2ledger-1.1.0

[back to package description]

fints2ledger

Build Status languages

A tool for downloading transactions from FinTS banking APIs and sorting them into a ledger journal.

pyfints is used to download the transactions. A list of compatible banks can be found there. This tool was tested with ING and GLS Bank.

There is a pure python implementation available on the python branch.

Contents

Install

You need Python version 3.6 or higher. Install the Python dependencies using:

pip3 install "fints>=4,<5" "mt-940>=4.11,<5"

Next, you can install fints2ledger either from a pre-built binary or from source.

from a pre-built binary

Simply grab the package from the releases page. On Unix, don't forget to make the binary executable with chmod +x fints2ledger.

from source

For this you need stack installed (or alternatively cabal). Then run

git clone git@github.com:MoritzR/fints2ledger.git
cd fints2ledger
stack install

This might take a while.

Usage

You can try out the program with the demo flag, which does not call any banking API.

fints2ledger --demo

To use a real connection run

fints2ledger

and enter your banking credentials in the following form. This only needs to be done once. The full configuration is stored in ~/.config/fints2ledger/config.yml.

For a list of available command line arguments, run

fints2ledger --help

Automatically matching transactions

In the ledger section you can use a regex match on any field of the transaction data to automatically fill other fields. The amount field uses comparison symbols instead of a regex. Valid values are for example "<=90.5", "120.13", "> 200"

Example: I do not want to enter a credit_account and purpose for my monthly recurring payments for the rent of my apartment. Same for my music streaming transactions. I can change the config.yml like this:

ledger:
  ...
  fills:
    - match:
        payee: "The Landlord"
        purpose: "Rent for apartment B month.*"
      fill:
        credit_account: "expenses:monthly:rent"
        purpose: "monthly rent"
    - match:
        payee: "MUSIC COMPANY 123"
      fill:
        credit_account: "expenses:monthly:musiccompany"
        purpose: "Monthly fee for music streaming"

To only fill out parts of the transaction while still being prompted for others, leave the value empty for the fields that you like to be prompted for. The following will fill out credit_account but still prompt for purpose (instead of taking the purpose from the original transaction).

ledger:
  ...
  fills:
    - match:
        payee: "The Landlord"
      fill:
        credit_account: "expenses:monthly:rent"
        purpose:

Changelog

The changelog can be found in CHANGELOG.md

Contributing

For additional information on how to work with the repository, see CONTRIBUTING.md