Skip to main content

AgentSync Python SDK

Python SDK for the AgentSync x402 micropayment gateway on Radix.

Install

pip install agentsync-sdk

Note: the distribution name is agentsync-sdk; the import package remains agentsync (from agentsync import ...). For local development use pip install -e . in the repo.

Development

pip install -e ".[dev]"
pytest

Platform Attestation Verification

Verify a platform-signed attestation envelope against the trusted platform Ed25519 public key:

from agentsync import SignatureEnvelope, verify_platform_attestation

trusted_public_key = "9afcc1cf66b256d7d9567a906fba4317305d92c3e7fd7f27386dffe182332576"
envelope = SignatureEnvelope(
    payload="account_tdx_2_...:5.500000:0",
    signature="<128-char hex>",
    public_key=trusted_public_key,
    algorithm="ed25519+sha256",
)

valid = verify_platform_attestation(envelope, trusted_public_key)  # bool

verify_platform_attestation() is pure and synchronous: the trusted key is injected by the caller and never fetched from the network. It asserts that the envelope's public_key matches the trusted key before verifying the Ed25519(SHA-256(payload)) signature.

The TypeScript counterpart lives at ../sdk-typescript.

Download files

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

Source Distribution

agentsync_sdk-1.0.0.tar.gz (19.0 kB view details)

Uploaded Source

Built Distribution

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

agentsync_sdk-1.0.0-py3-none-any.whl (14.3 kB view details)

Uploaded Python 3

File details

Details for the file agentsync_sdk-1.0.0.tar.gz.

File metadata

  • Download URL: agentsync_sdk-1.0.0.tar.gz
  • Upload date:
  • Size: 19.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.5

File hashes

Hashes for agentsync_sdk-1.0.0.tar.gz
Algorithm Hash digest
SHA256 de3c0600a2e6f60634e7f11a0fbcf225244fda9736fb2343968ab08be512d371
MD5 2b2bf1b174f19b2d9bc03f2731fae6da
BLAKE2b-256 5dbcf0340234a849cee870476f940b8128b406c63c8c5dd55a2a31f5664d0b4b

See more details on using hashes here.

File details

Details for the file agentsync_sdk-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: agentsync_sdk-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 14.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.5

File hashes

Hashes for agentsync_sdk-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d6c764a056bd732fcecc9a255abf62bab98799f485da21dd741cc5c0510be8c6
MD5 a413989787dfa2b8b5639c1a914ec920
BLAKE2b-256 0a11dc5a501babfa7fdb34682fc8a51389e0b5e9d422e5458a2081f67639045b

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page