Coder Social home page Coder Social logo

csogilvie / pymonzo Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pawelad/pymonzo

0.0 0.0 0.0 349 KB

Modern Python API client for Monzo public API.

Home Page: https://pymonzo.pawelad.dev/

License: Mozilla Public License 2.0

Python 99.11% Makefile 0.89%

pymonzo's Introduction

pymonzo

Package Version Supported Python Versions Read the Docs Codecov License Code style: black py.typed

Modern Python API client for Monzo public API.

  • Works on Python 3.8+
  • Fully type annotated
  • Explicitly defined and validated API schemas (via pydantic)
  • Easy authentication with automatic access token refreshing
  • Sensible defaults - don't specify account / pot ID if you only have one active
  • Optional rich support for pretty printing

This project is not officially affiliated with Monzo.

Installation

From PyPI (ideally, inside a virtualenv):

$ python -m pip install pymonzo

Quick start

Here's an example of what pymonzo can do:

>>> from pymonzo import MonzoAPI
>>> monzo_api = MonzoAPI()
>>> accounts = monzo_api.accounts.list()
>>> len(accounts)
2
>>> # Only one active account, so we don't need to pass it explicitly
>>> monzo_api.balance.get()
MonzoBalance(balance=75000, total_balance=95012, currency='GBP', spend_today=0, balance_including_flexible_savings=95012, local_currency='', local_exchange_rate=0, local_spend=[])
>>> from pymonzo.utils import n_days_ago
>>> transactions = monzo_api.transactions.list(since=n_days_ago(5))
>>> len(transactions)
8

Authors

Developed and maintained by Paweł Adamczak.

Source code is available at GitHub.

If you'd like to contribute, please take a look at the contributing guide.

Released under Mozilla Public License 2.0.

pymonzo's People

Contributors

bartonp avatar csogilvie avatar pawelad avatar sheaffy avatar

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.