/py-money

A Python interface to MoneyMoney

Primary LanguagePythonBSD 2-Clause "Simplified" LicenseBSD-2-Clause

py-money

A Python interface to MoneyMoney

Examples

import money

instance = money.MoneyMoney()

for account in instance.accounts():
    print(f"{account.name}: {account.balance:0.2f} {account.currency}")
    for tx in account.transactions():
        print(f"Transaction: {tx.payee}: {tx.amount:0.2f}")

Only print new transactions (checked=False) which are already booked. After printing them out, set the state to 'checked' so that they will not be seen in the next invocation.

for account in instance.accounts():
    for tx in account.transactions(age=90, booked=True, checked=False):
        print(f"New transaction: {tx}")
        tx.set_checkmark()

Install

pip install git+https://github.com/jerik/py-money.git#egg=py-money

or

python -m pip install git+https://github.com/jerik/py-money.git#egg=py-money