Python Interface for CoinTracking.info API
Project description
# python-ctapi
Python interface for [CoinTracking.info API](https://cointracking.info/api/api.php).
I am not associated to cointracking.info -- use at your own risk!
# Requirements:
* requests
# Install
`python setup.py install`
`pip install python-ctapi`
# How to Use
This is an example about how you can use the library
```
#!/usr/bin/env python2
from ctapi import CTAPI
api_key = <YourAPIKey>
api_secret = <YourAPISecret>
# api = CTAPI(api_key, api_secret, debug=True)
api = CTAPI(api_key, api_secret)
trades = api.getTrades()
if trades['success']:
for t in trades['result']:
print trades['result'][t]
else:
print "got no orders"
print api.getBalance()
print api.getHistoricalSummary()
print api.getHistoricalCurrency()
print api.getGroupedBalance()
print api.getGains()
```
# Running Tests
**be aware of the API requests limit of 20 req/h**
`venv/bin/python -m unittest -v ctapi.test.ctapi_tests`
# Contribute
Do you have an idea or found a bug in python-ctapi? Please file an issue and make a PR! :)
## Support Me
If you like the API and wanna support its developer, use the following referral link when registering at cointracking: https://cointracking.info?ref=T161519
Python interface for [CoinTracking.info API](https://cointracking.info/api/api.php).
I am not associated to cointracking.info -- use at your own risk!
# Requirements:
* requests
# Install
`python setup.py install`
`pip install python-ctapi`
# How to Use
This is an example about how you can use the library
```
#!/usr/bin/env python2
from ctapi import CTAPI
api_key = <YourAPIKey>
api_secret = <YourAPISecret>
# api = CTAPI(api_key, api_secret, debug=True)
api = CTAPI(api_key, api_secret)
trades = api.getTrades()
if trades['success']:
for t in trades['result']:
print trades['result'][t]
else:
print "got no orders"
print api.getBalance()
print api.getHistoricalSummary()
print api.getHistoricalCurrency()
print api.getGroupedBalance()
print api.getGains()
```
# Running Tests
**be aware of the API requests limit of 20 req/h**
`venv/bin/python -m unittest -v ctapi.test.ctapi_tests`
# Contribute
Do you have an idea or found a bug in python-ctapi? Please file an issue and make a PR! :)
## Support Me
If you like the API and wanna support its developer, use the following referral link when registering at cointracking: https://cointracking.info?ref=T161519
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
python-ctapi-0.3.0.tar.gz
(3.6 kB
view hashes)
Built Distribution
Close
Hashes for python_ctapi-0.3.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 398ffc258c7983fc25885aad86fa6fc1f0780235f0abc86aa3667e70a905f1f9 |
|
MD5 | 626c749e21f5bf8c2ea97e8fb6888793 |
|
BLAKE2b-256 | b154c572a258f5b5b8a5f6b366f021c5cf415903213c7a306edfef7b8fd73806 |