Skip to content

Python SDK Overview

Full-featured Python SDK for Auths decentralized identity, backed by Rust via PyO3. Create identities, sign commits and artifacts, verify attestation chains, and manage organizations — all from Python.

Installation

pip install auths

Pre-built wheels for Linux, macOS, and Windows (Python 3.8+ via ABI3). No Rust toolchain required.

For JWT token verification, install the optional dependency:

pip install auths[jwt]

Quick taste

from auths import Auths

client = Auths()
identity = client.identities.create(label="laptop")
result = client.sign_commit(commit_bytes, identity_did=identity.did)
print(result.signature_pem)

What you can do

Feature Service API Reference
Create and rotate identities client.identities Identities
Link, extend, and revoke devices client.devices Devices
Query attestation chains client.attestations Attestations
Sign commits and artifacts client.sign_commit(), client.sign_artifact() Client, Signing
Verify attestations and chains client.verify(), client.verify_chain() Client, Verification
Build authorization policies PolicyBuilder Policy
Manage organizations client.orgs Organizations
Verify OIDC bridge tokens AuthsJWKSClient JWT
Authenticate CI agents AgentAuth Agent Auth
Verify git commit ranges verify_commit_range() Git

Architecture

The Python SDK is a thin wrapper over the Rust auths-sdk crate via PyO3. All cryptographic operations happen in Rust — the Python layer provides Pythonic dataclasses, error types, and service objects.

Python (auths.*)  →  PyO3 bridge (auths._native)  →  Rust (auths-sdk)

Next steps