Skip to main content

Official Python SDK for the Walley wallet API on Canton Network

Project description

walley-sdk

Official Python SDK for Walley — programmatic self-custody of CIP-56 tokens on Canton Network. Your process holds the wallet's key, signs locally, and submits transactions; the API only ever sees public keys and signatures.

pip install walley-sdk
from walley import Walley

w = Walley(
    key_file="~/.config/walley/alice.key",   # PEM or 24-word mnemonic file
    party_hint="walley-alice",
)

for balance in w.balances:
    print(balance.instrument_id, balance.total_balance)

result = w.transactions.execute(commands)   # your dapp's own ledger commands
result = w.transfers.send(receiver="walley-bob::1220...", amount="5")
print(result.update_id, result.fee)

Transaction fees are drawn from a prepaid traffic balance. Pre-buy traffic, then send freely; each fee is reserved from the balance and settled from the completion — no per-transaction payment step:

w.traffic.purchase("10")               # buy 10 CC of traffic
print(w.traffic.balance().available)   # spendable balance (may go negative once)

If the balance goes negative the next send raises InsufficientTrafficError — call w.traffic.purchase(amount) to continue.

Full documentation: docs.walley.cc/python-sdk — quickstart, keys & authentication, transactions & the prepaid traffic model, wallet operations, and ledger reads.

Development

cd walley-sdk
pip install -e '.[dev]'
pytest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

walley_sdk-0.2.0.tar.gz (19.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

walley_sdk-0.2.0-py3-none-any.whl (30.9 kB view details)

Uploaded Python 3

File details

Details for the file walley_sdk-0.2.0.tar.gz.

File metadata

  • Download URL: walley_sdk-0.2.0.tar.gz
  • Upload date:
  • Size: 19.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.6

File hashes

Hashes for walley_sdk-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6a872536f017af296fdce9432118ad6fc3f5090d5be18868049ca4af5f5947e4
MD5 50f953a22c8f048d0aa18fa276d47549
BLAKE2b-256 1a78a1506dd80aa75fba058ff34a8ea44d480d84eb0ebeb917c82afb0bdf7909

See more details on using hashes here.

File details

Details for the file walley_sdk-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: walley_sdk-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 30.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.6

File hashes

Hashes for walley_sdk-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 64d4bb700510b6b82748526f0133a340d4439643e4cd9046817edcbc2ffbc621
MD5 047bbe6922e28bb9c15b2aecb44f093e
BLAKE2b-256 4109bf1e9c814083dfefbc918c4fc5e82c11407f007f4e0e1523f400c4a321bc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page