SDK · Python
beacons-sdk on PyPI. Async-first.
The Python SDK is async-first and anyio-compatible. It binds to the Rust crypto core through PyO3 so signatures verify identically across languages. Works on CPython 3.10+ and PyPy.
Install
uv add beacons-sdk # or pip install beacons-sdk poetry add beacons-sdk
What you get
- asyncio + anyio compatible
- PyO3 crypto core — Rust-grade signatures from Python
- Type-annotated; mypy --strict clean
- Sync wrappers for scripts; async for services
Platforms: CPython 3.10+ · PyPy 3.10+ · Linux · macOS · Windows
python — enroll a peer
import asyncio
from beacons import Client, Did, Fleet
async def main():
client = await Client.from_env()
fleet = Fleet.parse("did:oas:acme:fleet:prod")
me = Did.parse("did:oas:acme:agent:scribe-7")
peer = await client.fleet(fleet).enroll(me)
print(f"admitted in {peer.composite_verdict_ms} ms")
asyncio.run(main())Parity
Identical surface in every language.
Every Beacons SDK targets the same set of operations. Cryptographic primitives (Ed25519, HKDF-SHA256, Blake3) come from a shared Rust WASM module so signatures produced in one language verify identically in another. The conformance suite at beacons-conformance exercises cross-language vectors on every release.