Lichen Python SDK
Official Python SDK for interacting with Lichen blockchain.
Installation
pip install lichen-sdk
Quick Start
import asyncio
from lichen import Connection, Keypair, PublicKey
async def main():
# Connect to Lichen
connection = Connection('http://localhost:8899')
# Generate a native PQ keypair
keypair = Keypair.generate()
print(f"Address: {keypair.pubkey().to_base58()}")
# Get account balance
pubkey = PublicKey('YourPublicKeyHere...')
balance = await connection.get_balance(pubkey)
print(f"Balance: {balance['licn']} LICN")
# Subscribe to blocks
async def on_block(block):
print(f"New block: {block}")
await connection.on_block(on_block)
asyncio.run(main())
Features
- ✅ Complete async RPC client (24 endpoints)
- ✅ WebSocket subscriptions (real-time events)
- ✅ Native PQ keypairs and self-contained signatures
- ✅ Transaction builder
- ✅ Type hints throughout
- ✅ Address and PQ public-key utilities
- ✅ Full blockchain interaction
Documentation
See the Python SDK reference for detailed API reference.
License
MIT
Metadata
Release files for lichen-sdk 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| lichen_sdk-1.0.0.tar.gz | 30.4 kB | Without provenance | Details for lichen_sdk-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| lichen_sdk-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for lichen_sdk-1.0.0-py3-none-any.whl |
Total release size: 67.4 kB
Release files / lichen_sdk-1.0.0.tar.gz
| Download URL | lichen_sdk-1.0.0.tar.gz |
|---|---|
| Size | 30.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
115a7d0914a9476725c0ccb339f557b79dd44b2e7ea9ce392fe124b8f745a27e
|
|
BLAKE2b-256 checksum How to use checksums |
a2c87f6ada269e14540ddfb6a1f6fc84c24a99e9051dd5c9855832c2acef93be
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.3
|
Release files / lichen_sdk-1.0.0-py3-none-any.whl
| Download URL | lichen_sdk-1.0.0-py3-none-any.whl |
|---|---|
| Size | 37.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e00ded1929483975d92273df50dbc573827f67cf7bd9a4631f618e4951ca0ff7
|
|
BLAKE2b-256 checksum How to use checksums |
0ca218e09c895d04b64fc1b3202b1bcb3df5d7bb3b025141f3cc0ac70358dc83
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.3
|
Security for lichen-sdk 1.0.0
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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.