Skip to main content

AgentOath A2A Bridge

AgentOath trust protocol extension for the Google A2A (Agent-to-Agent) protocol.

Embeds verifiable identity, trust scores, and signed receipts into A2A agent communication, adding cryptographic trust to inter-agent interactions.

Features

  • Agent Card Extension -- Add AgentOath identity (DID, public key, trust score) to A2A Agent Cards
  • Task Handler -- Automatically sign trust receipts when A2A tasks complete or fail
  • Trust Headers -- Sign and verify HTTP headers for A2A requests
  • ASGI Middleware -- Drop-in middleware for A2A servers (FastAPI, Starlette, etc.)

Quick Start

pip install agentoath-a2a

Extend your Agent Card

from agentoath import TrustAgent
from agentoath_a2a import AgentCardExtension

agent = TrustAgent.load("my_agent.json")
ext = AgentCardExtension(agent)

card = {
    "name": "My Agent",
    "description": "An AI assistant",
    "url": "https://myagent.example.com",
}
card = ext.extend_agent_card(card)
# card now has extensions.agentoath with DID, public_key, trust_score

Automatic receipts on task completion

from agentoath_a2a import TrustTaskHandler

handler = TrustTaskHandler(agent)

# When an A2A task completes:
receipt = handler.on_task_completed(task, remote_agent_did="did:trust:agent:...", rating=8)

Trust headers for HTTP requests

from agentoath_a2a import TrustHeaderSigner, TrustHeaderVerifier

# Sign outgoing request
signer = TrustHeaderSigner(agent)
headers = signer.sign_headers(method="POST", path="/tasks/send")

# Verify incoming request
verifier = TrustHeaderVerifier()
result = verifier.verify_headers(headers, "POST", "/tasks/send", public_key=remote_agent.public_key)

ASGI Middleware

from agentoath_a2a import AgentOathA2AMiddleware

app = AgentOathA2AMiddleware(app, agent=agent, known_agents={...})

Development

pip install -e ".[dev]"
pytest

License

Apache-2.0

Download files

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

Source Distribution

agentoath_a2a-0.2.0.tar.gz (20.6 kB view details)

Uploaded Source

Built Distribution

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

agentoath_a2a-0.2.0-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: agentoath_a2a-0.2.0.tar.gz
  • Upload date:
  • Size: 20.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.12

File hashes

Hashes for agentoath_a2a-0.2.0.tar.gz
Algorithm Hash digest
SHA256 90df6531a02836375412c52c5b55593cab8a481045163bcb07522dacab351a1f
MD5 ce6f33ae79740cace9113944f884f74a
BLAKE2b-256 84b11b7531aab6afb93d0c9c66715e9539414e5ef25340a5cc92016751013df0

See more details on using hashes here.

File details

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

File metadata

  • Download URL: agentoath_a2a-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 17.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.12

File hashes

Hashes for agentoath_a2a-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cf327aa044958bb65840665ad4510f6a8084490c34bd6597d424c411586bdc9d
MD5 150653f3c0d81a0e1eab4a492f04cc84
BLAKE2b-256 3a077af53300de9c9bd70876892328f576de9176f3d2cf02309fd81b53e05e75

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 files

0.1.0

2 files

Supported by

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