Coinbase Advanced Trade API client library.
Project description
Coinbase Advanced
Python library for the Coinbase Advanced Trade API.
Features
- Support for all the REST API endpoints through convenient methods.
- Automatic parsing of API responses into relevant Python objects.
- Unit Tests based on real responses using fixtures.
- Support for Cloud and Legacy Auth Schemas:
- Support for Cloud API Trading Keys (Recommended)
- Support for Legacy API Keys (Deprecated but supported in this library for backward compatibility reasons)
Example
from coinbaseadvanced.client import CoinbaseAdvancedTradeAPIClient
# Creating the client using Clould API Keys.
client = CoinbaseAdvancedTradeAPIClient.from_cloud_api_keys(API_KEY_NAME, PRIVATE_KEY)
# Listing accounts.
accounts_page = client.list_accounts()
print(accounts_page.size)
# Creating a limit order.
order_created = client.create_limit_order(client_order_id="lknalksdj89asdkl", product_id="ALGO-USD", side=Side.BUY, limit_price=".19", base_size=5)
Installation
pip install coinbaseadvanced
Contributing/Development
Any and all contributions are welcome! The process is simple:
- Fork repo.
- Install Requirements:
pip install -r requirements.txt
. - Make your changes.
- Run the test suite
python -m unittest -v
. - Submit a pull request.
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 Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
File details
Details for the file coinbaseadvanced-1.1.0-py3-none-any.whl
.
File metadata
- Download URL: coinbaseadvanced-1.1.0-py3-none-any.whl
- Upload date:
- Size: 25.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.8.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2605dea60723a0f4193c8ab81a9597e500b2cafcf87be938ef87cbab42d31955 |
|
MD5 | af4edb5d3a1bacc9987e57a98880b9fc |
|
BLAKE2b-256 | 8ad04ad3b9573e64e1c2d33ded6ed93e610d9a0e92ea218e86768b5a696cd8e9 |