Skip to content

A user-friendly Kraken API client using pydantic πŸ™

Notifications You must be signed in to change notification settings

marc-at-brightnight/krakenpull

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

23 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Kraken-pull

A user friendly Kraken API client using pydantic πŸ™

Installation πŸ’Ώ

The easiest way to use krakenpull is to install via pip:

pip install krakenpull

Usage πŸͺš

Initialize a kraken client:

from krakenpull import Kraken

client = Kraken(key, private_key)

Common methods and features:

# get account balance
balances = client.get_account_balance()
print(balances) # {Currency.XBT: 5.23}

# get closed orders
closed_orders = client.get_closed_orders()
print(closed_orders) # [ClosedTransactions(...), ...]

# get order book
from krakenpull import Currency
order_book = client.get_order_book(currency_pair=(Currency.XBT, Currency.USD))
print(order_book) # {"asks": ["69854.10000", "17.384", 1711832989], "bids": ["69854.00000", "0.015", 1711832988]} 

Contributing πŸ§‘β€πŸ’»

Issues, PRs and other contributions are always welcome.

Please note this repository uses black for formatting, ruff for linting and mypy for type checking.

Pre-commit hooks help to make committing easier by automating running black and ruff so if you want to make use of them, you can install them by using the following commands:

brew install pre-commit
pre-commit install --install-hooks
pre-commit install --hook-type commit-msg

About

A user-friendly Kraken API client using pydantic πŸ™

Resources

Stars

Watchers

Forks

Packages

No packages published