Skip to content

Python SDK

View as Markdown

The Python SDK is a uv workspace with one package per public API surface. The packages require Python 3.11 or later.

SurfacePackage or moduleRelease status
Connectsudomimus-connectSource only
Sessionsudomimus-sessionSource only
Devicesudomimus-deviceSource only
Nativesudomimus-nativeSource only
Tokensudomimus-tokenSource only

Release status verified: .

Until a package is marked Published above, consume it from a checked-out SDK repository rather than assuming it is available from PyPI.

from sudomimus_connect import ConnectClient, ConnectClientAuthWithKey
from sudomimus_session import SessionClient
connect = ConnectClient(client_auth=ConnectClientAuthWithKey(
application_anchor="your-app-anchor",
private_key_pem=private_key_pem,
))
session = SessionClient()

Connect starts and redeems the browser inquiry. Session owns refresh, introspection, logout, and revoke-all after a flow issues tokens. Keep the client-auth private key and refresh tokens on the server.

For Django applications, prefer the Django framework SDK, which owns the callback and token-rotation plumbing.

Use sudomimus-device for public clients that cannot hold a client secret. Use sudomimus-native to exchange Steam tickets, AccessKeys, or signed public-key assertions. Both return ordinary Sudomimus tokens that continue through sudomimus-session.