Skip to main content

PDF parsing for Singaporean banks

Project description


Tests CI Code style: black Linting: pylint License: MIT

Monopoly is a Python library that converts Singapore bank statement PDFs to CSV using pdftotext

Supported banks:

Bank Credit Statement Debit Statement
Citibank :white_check_mark: :x:
DBS :white_check_mark: :white_check_mark:
HSBC :white_check_mark: :x:
OCBC :white_check_mark: :white_check_mark:
Standard Chartered :white_check_mark: :x:

Install

Clone the repo

git clone https://github.com/benjamin-awd/monopoly.git

Install dependencies using Homebrew

brew install make
make setup

Usage

Monopoly can be run as a Python package, allowing you to extract, transform and write bank statements to a CSV file.

To see how Monopoly works, you can run this example

python3 src/monopoly/examples/single_statement.py

If you need to run monopoly on a password protected file, ensure that passwords are set in the .env file:

cp .env.template env

If you have multiple statements from the same bank with different passwords (e.g. HSBC statements), make sure to set both passwords in an array format like so:

HSBC_PDF_PASSWORDS=["password1","password2"]

Features

  • Unlocks PDFs using user-provided credentials
  • Statements can be parsed with the CLI, or manually with the bank processor class.
  • Support for cashback transactions and refunds
  • Monopoly can be run on Google Cloud as a scheduled Cloud Run job, which opens up more sophisticated use-cases like historical analysis and personal finance visualization

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

monopoly_sg-0.7.2.tar.gz (212.1 kB view details)

Uploaded Source

Built Distribution

monopoly_sg-0.7.2-py3-none-any.whl (218.4 kB view details)

Uploaded Python 3

File details

Details for the file monopoly_sg-0.7.2.tar.gz.

File metadata

  • Download URL: monopoly_sg-0.7.2.tar.gz
  • Upload date:
  • Size: 212.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.12.1 Linux/5.15.146.1-microsoft-standard-WSL2

File hashes

Hashes for monopoly_sg-0.7.2.tar.gz
Algorithm Hash digest
SHA256 7843fa0d138f3ff3a174854db41ca022d22ca2b1f073f0bd106b6fc14ac30f53
MD5 177bfd9adce32b48fa15c4592591f7a0
BLAKE2b-256 b1687e31adeb43602da2ab9b058085ce334e06445831d43642e4909d1a25b8cd

See more details on using hashes here.

File details

Details for the file monopoly_sg-0.7.2-py3-none-any.whl.

File metadata

  • Download URL: monopoly_sg-0.7.2-py3-none-any.whl
  • Upload date:
  • Size: 218.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.12.1 Linux/5.15.146.1-microsoft-standard-WSL2

File hashes

Hashes for monopoly_sg-0.7.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5a21cf44aa599e7970e0e0d6efd6f434bc7e96d63031fce35f394d04c9d99b4d
MD5 1a8ccbeef72bf8962032255d3ae6fb79
BLAKE2b-256 c7fef82334356ce9a87a026c0d4b19f48266b7003a230596a41ab20647813d6d

See more details on using hashes here.

Supported by

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