Coder Social home page Coder Social logo

pianoslum / ofxstatement Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kedder/ofxstatement

0.0 1.0 0.0 193 KB

Tool to convert proprietary bank statement to OFX format, suitable for importing to GnuCash.

License: GNU General Public License v3.0

Python 98.48% Makefile 1.52%

ofxstatement's Introduction

OFX Statement

https://travis-ci.org/kedder/ofxstatement.png?branch=master https://coveralls.io/repos/kedder/ofxstatement/badge.png?branch=master

Ofxstatement is a tool to convert proprietary bank statement to OFX format, suitable for importing to GnuCash. Package provides single command line tool to run: ofxstatement. Run ofxstatement -h to see basic usage description. ofxstatement works under Python 3 and is not compatible with Python 2.

Rationale

Most internet banking systems are capable of exporting account transactions to some sort of computer readable formats, but few supports standard data formats, like OFX. On the other hand, personal accounting tools, such as GnuCash support standard formats only, and will probably never support proprietary statement formats of online banking systems.

To bridge the gap between them, ofxstatement tool was created.

Mode of Operation

The ofxstatement tool is intended to be used in the following workflow:

  1. At the end of each month, use your online banking service to export statements from all of your bank accounts to files in formats, known to ofxstatement.
  2. Run ofxstatement on each exported file to convert it to standard OFX format. Shell scripts or Makefile may help to automate this routine.
  3. Import generated OFX files to GnuCash or other accounting system.

Installation and Usage

Before using ofxstatement, you have to install plugin for your bank (or write your own!). Plugins are installed as regular python eggs, with easy_install or pip, for example:

$ pip3 install ofxstatement-lithuanian

Note, that ofxstatement itself will be installed automatically this way. After installation, ofxstatement utility should be available.

Users of Ubuntu and Debian operating systems can install ofxstatement from official package repositories:

$ apt install ofxstatement ofxstatement-plugins

You can check ofxstatement is working by running:

$ ofxstatement list-plugins

You should get a list of your installed plugins printed.

After installation, usage is simple:

$ ofxstatement convert -t <plugin> bank_statement.csv statement.ofx

Resulting statement.ofx is then ready to be imported to GnuCash or other financial program you use.

Known Plugins

There are several user-developed plugins available:

Plugin Description
ofxstatement-lithuanian Plugins for several banks, operating in Lithuania: Swedbank, Danske and common Lithuanian exchange format - LITAS-ESIS.
ofxstatement-czech Plugin for Poštovní spořitelna (maxibps) and banks using GPC format (e.g., FIO banka, module gpc).
ofxstatement-airbankcz Plugin for Air Bank a.s. (Czech Republic)
ofxstatement-raiffeisencz Plugin for Raiffeisenbank a.s. (Czech Republic)
ofxstatement-unicreditcz Plugin for UniCredit Bank Czech Republic and Slovakia
ofxstatement-otp Plugin for OTP Bank, operating in Hungary
ofxstatement-bubbas Set of plugins, developed by @bubbas: dkb_cc and lbbamazon.
banking.statements.osuuspankki Finnish Osuuspankki bank
banking.statements.nordea Nordea bank (at least Finnish branch of it)
`ofxstatement-1822direkt`_ German bank 1822direkt.com
ofxstatement-austrian Plugins for several banks, operating in Austria: Easybank, ING-Diba, Livebank, Raiffeisenbank.
ofxstatement-postfinance Swiss PostFinance (E-Finance Java text based bank/credit statements).
ofxstatement-mbank-sk MBank.sk
ofxstatement-be-keytrade KeytradeBank (Belgium)
ofxstatement-be-ing ING (Belgium)
ofxstatement-be-kbc KBC (Belgium)
ofxstatement-be-argenta Argenta (Belgium)
ofxstatement-betterment Betterment (https://www.betterment.com/)
ofxstatement-simple Simple (the bank, https://www.simple.com/) JSON financial statement format
ofxstatement-latvian Latvian banks
ofxstatement-iso20022 Support for generic ISO-20022 format
ofxstatement-seb SEB (Sweden), it parses Export.xlsx for private accounts
ofxstatement-alfabank AlfaBank (Russia), it parses movementList.csv for private accounts
ofxstatement-paypal PayPal, it parses *.csv for private accounts
ofxstatement-polish Support for some Polish banks and financial institutions
ofxstatement-russian Support for several Russian banks: Avangard, Tinkoff, Sberbank (debit).
ofxstatement-dab DAB Bank (Germany)
ofxstatement-consors Consorsbank (Germany)
ofxstatement-is-arionbanki Arion bank in Iceland
ofxstatement-be-triodos Triodos Bank CSV statements
ofxstatement-lansforsakringar Länsförsäkringar (Sweden), it parses Kontoutdrag.xls for private accounts
ofxstatement-revolut Revolut Mastercard
ofxstatement-sp-freiburg Sparkasse Freiburg-Nördlicher Breisgau (Germany)
ofxstatement-al_bank Arbejdernes Landsbank (Denmark)
ofxstatement-fineco FinecoBank (Italy)
ofxstatement-intesasp Intesa San Paolo (xlsx balance file)
ofxstatement-de-ing Ing Diba Bank (Germany)

Advanced Configuration

While ofxstatement can be used without any configuration, some plugins may accept additional configuration parameters. These parameters can be specified in configuration file. Configuration file can be edited using edit-config command, that brings your favored editor with configuration file open:

$ ofxstatement edit-config

Configuration file format is a standard .ini format. Configuration is divided to sections, that corresponds to --type command line parameter. Each section must provide plugin option that points to one of the registered conversion plugins. Other parameters are plugin specific.

Sample configuration file:

[swedbank]
plugin = swedbank

[danske:usd]
plugin = litas-esis
charset = cp1257
currency = USD
account = LT123456789012345678

Such configuration will let ofxstatement to know about two statement file format, handled by plugins swedbank and litas-esis. litas-esis plugin will load statements using cp1257 charset and set custom currency and custom account number. This way, GnuCash will automatically associate imported .ofx statement with particular GnuCash account.

To convert proprietary danske.csv to OFX danske.ofx, run:

$ ofxstatement -t danske:usd danske.csv danske.ofx

Note, that configuration parameters are plugin specific. See particular plugin documentation for more info.

Writing your own Plugin

If plugin for your bank is not yet developed (see Known plugins section above), you can easily write your own, provided some knowledge about python programming language. There is an ofxstatement-sample plugin project available, that provides sample boilerplate and describes plugin development process in detail.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.