```
_____ _
|_ _|_ _ _ __ __ _ ___ _ __(_)_ __ ___
| |/ _` | '_ \ / _` |/ _ \ '__| | '_ \ / _ \
| | (_| | | | | (_| | __/ | | | | | | __/
|_|\__,_|_| |_|\__, |\___|_| |_|_| |_|\___|
|___/
```
[](https://pypi.python.org/pypi/tangerine)
[](https://circleci.com/gh/kevinjqiu/tangerine)
[](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)
```
Contribution
============
Requirements:
* Python 3
* [pipenv](https://github.com/kennethreitz/pipenv)
* basic knowledge of Python and git
To contribute to the development, fork this repo to your github account, and clone it.
```
$ git clone https://YOUR-CLONE-URL tangerine
$ cd tangerine
$ pipenv install # this creates the virtualenv and installs the dependencies
$ pipenv shell # this activates the virtualenv
$ git checkout -b branch-for-feature-or-bug-fix
HACK...HACK...HACK
$ git commit ...
$ git push
```
and send a PR :)
Licence
=======
MIT
Changelog
=========
See [CHANGELOG.md](CHANGELOG.md)
Authors
=======
tangerine was written by Kevin J. Qiu <kevin@idempotent.ca> with [contributors](https://github.com/kevinjqiu/tangerine/graphs/contributors).
_____ _
|_ _|_ _ _ __ __ _ ___ _ __(_)_ __ ___
| |/ _` | '_ \ / _` |/ _ \ '__| | '_ \ / _ \
| | (_| | | | | (_| | __/ | | | | | | __/
|_|\__,_|_| |_|\__, |\___|_| |_|_| |_|\___|
|___/
```
[](https://pypi.python.org/pypi/tangerine)
[](https://circleci.com/gh/kevinjqiu/tangerine)
[](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)
```
Contribution
============
Requirements:
* Python 3
* [pipenv](https://github.com/kennethreitz/pipenv)
* basic knowledge of Python and git
To contribute to the development, fork this repo to your github account, and clone it.
```
$ git clone https://YOUR-CLONE-URL tangerine
$ cd tangerine
$ pipenv install # this creates the virtualenv and installs the dependencies
$ pipenv shell # this activates the virtualenv
$ git checkout -b branch-for-feature-or-bug-fix
HACK...HACK...HACK
$ git commit ...
$ git push
```
and send a PR :)
Licence
=======
MIT
Changelog
=========
See [CHANGELOG.md](CHANGELOG.md)
Authors
=======
tangerine was written by Kevin J. Qiu <kevin@idempotent.ca> with [contributors](https://github.com/kevinjqiu/tangerine/graphs/contributors).
Metadata
Release files for tangerine 0.3.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tangerine-0.3.9-py3-none-any.whl | Python 3 | none | any | Details |
Release files / tangerine-0.3.9-py3-none-any.whl
| Download URL | tangerine-0.3.9-py3-none-any.whl |
|---|---|
| Size | 8.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6e52232429222e78c7d38073d3efae031595ebe8051d97d1a5e73cff29c8ee0e
|
|
BLAKE2b-256 checksum How to use checksums |
484ce6138e1c04e9b4b0d1082ab7c6e348665f44c19a674e8077e9fc4d4e6638
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for tangerine 0.3.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.