API for the Tangerine Bank
Project description
```
_____ _
|_ _|_ _ _ __ __ _ ___ _ __(_)_ __ ___
| |/ _` | '_ \ / _` |/ _ \ '__| | '_ \ / _ \
| | (_| | | | | (_| | __/ | | | | | | __/
|_|\__,_|_| |_|\__, |\___|_| |_|_| |_|\___|
|___/
```
[![Latest PyPI version](https://img.shields.io/pypi/v/tangerine.svg)](https://pypi.python.org/pypi/tangerine)
[![CircleCI](https://circleci.com/gh/kevinjqiu/tangerine.svg?style=svg)](https://circleci.com/gh/kevinjqiu/tangerine)
[![codecov](https://codecov.io/gh/kevinjqiu/tangerine/branch/master/graph/badge.svg)](https://codecov.io/gh/kevinjqiu/tangerine)
API and scraper for the Tangerine Bank (Canada).
Install
=======
pip install tangerine
Usage
=====
Authentication
--------------
```python
from tangerine import InteractiveSecretProvider, TangerineClient
secret_provider = InteractiveSecretProvider()
client = TangerineClient(secret_provider)
with client.login():
...
```
Using `InteractiveSecretProvider` will prompt user for username/account #, security challenge questions and PIN number.
The call to `client.login()` will initiate the login process. After the login is successful, subsequent calls to the API will be authenticated.
If `client.login()` is used as a context manager (i.e., `with client.login():`), logout will be automatically initiated after the code block exits
or any exception is raised.
List accounts
-------------
With an active session, use `client.list_accounts()`:
```python
with client.login():
accounts = client.list_accounts()
```
List transactions
-----------------
```python
with client.login():
accounts = client.list_accounts()
start_date = datetime.date(2017, 10, 1)
end_date = datetime.date(2017, 11, 1)
client.list_transactions([acct['number'] for acct in accounts], start_date, end_date)
```
Download statements
-------------------
```python
with client.login():
accounts = client.list_accounts()
start_date = datetime.date(2017, 10, 1)
end_date = datetime.date(2017, 11, 1)
client.download_ofx(account[0], start_date, end_date)
```
Licence
=======
MIT.
Authors
=======
tangerine was written by Kevin J. Qiu <kevin@idempotent.ca>
_____ _
|_ _|_ _ _ __ __ _ ___ _ __(_)_ __ ___
| |/ _` | '_ \ / _` |/ _ \ '__| | '_ \ / _ \
| | (_| | | | | (_| | __/ | | | | | | __/
|_|\__,_|_| |_|\__, |\___|_| |_|_| |_|\___|
|___/
```
[![Latest PyPI version](https://img.shields.io/pypi/v/tangerine.svg)](https://pypi.python.org/pypi/tangerine)
[![CircleCI](https://circleci.com/gh/kevinjqiu/tangerine.svg?style=svg)](https://circleci.com/gh/kevinjqiu/tangerine)
[![codecov](https://codecov.io/gh/kevinjqiu/tangerine/branch/master/graph/badge.svg)](https://codecov.io/gh/kevinjqiu/tangerine)
API and scraper for the Tangerine Bank (Canada).
Install
=======
pip install tangerine
Usage
=====
Authentication
--------------
```python
from tangerine import InteractiveSecretProvider, TangerineClient
secret_provider = InteractiveSecretProvider()
client = TangerineClient(secret_provider)
with client.login():
...
```
Using `InteractiveSecretProvider` will prompt user for username/account #, security challenge questions and PIN number.
The call to `client.login()` will initiate the login process. After the login is successful, subsequent calls to the API will be authenticated.
If `client.login()` is used as a context manager (i.e., `with client.login():`), logout will be automatically initiated after the code block exits
or any exception is raised.
List accounts
-------------
With an active session, use `client.list_accounts()`:
```python
with client.login():
accounts = client.list_accounts()
```
List transactions
-----------------
```python
with client.login():
accounts = client.list_accounts()
start_date = datetime.date(2017, 10, 1)
end_date = datetime.date(2017, 11, 1)
client.list_transactions([acct['number'] for acct in accounts], start_date, end_date)
```
Download statements
-------------------
```python
with client.login():
accounts = client.list_accounts()
start_date = datetime.date(2017, 10, 1)
end_date = datetime.date(2017, 11, 1)
client.download_ofx(account[0], start_date, end_date)
```
Licence
=======
MIT.
Authors
=======
tangerine was written by Kevin J. Qiu <kevin@idempotent.ca>
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tangerine-0.1.2.tar.gz
(5.4 kB
view hashes)
Built Distribution
Close
Hashes for tangerine-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ae44feddc3025ba5d04f657ee801e401929b17c150f19ae87dab30792e7d16fd |
|
MD5 | 8f8009d1d770d81c3d55cb3df6040896 |
|
BLAKE2b-256 | a0042bffdeaa63c5847980c37b30e7d475fa68820bd273965953d83ee19fe4f1 |