Bitbox-py: A Python SDK for creating great Bitcoin Cash applications
Bitbox-py is the Python port of Gabriel Cardona's great Bitcoin Cash Javascript SDK Bitbox.
I ported Bitbox to Python to make Bitcoin Cash more accessible to developers and therefore to the world.
Usage
Install Bitbox-py using Pip:
pip install bitbox-py
Documentation
Everything is basically the same as Bitbox-sdk, except methods are not using camelCase in order to fit with Python's style.
You can refer to the official Documentation.
Example:
Javascript:
import { BITBOX } from 'bitbox-sdk'
let bitbox = new BITBOX();
let result = bitbox.Address.toLegacyAddress('bitcoincash:qrxjktfjdse3ll0ttrll20gykuhqjw764queg3w2tj');
console.log(result);
// 1KhqFHWHUoJ72tuQCkhV1m1Sk7bXCiKJgN
Python:
import bitbox
result = bitbox.Address.to_legacy_address('bitcoincash:qrxjktfjdse3ll0ttrll20gykuhqjw764queg3w2tj')
print(result)
# 1KhqFHWHUoJ72tuQCkhV1m1Sk7bXCiKJgN
OR import by class:
from bitbox import Address
result = Address.to_legacy_address('bitcoincash:qrxjktfjdse3ll0ttrll20gykuhqjw764queg3w2tj')
print(result)
# 1KhqFHWHUoJ72tuQCkhV1m1Sk7bXCiKJgN
Contributing
You can find the instructions for contributing on CONTRIBUTING.md.
Features you can add that aren't implemented yet:
- ECPair utilities (fromWIF, fromPublicKey etc)
- HDNode methods (fromSeed, derive etc)
- Schnorr utilities
Notes and credits
- Gabriel Cardona for creating the original Javascript Bitbox-sdk, and for inspiring me everyday!
- Bitcoin.com for enabling millions of individuals to use an uncensorable peer-to-peer cash system everyday.
- Rosco Kalis for encouraging me to port Bitbox to Python.