This release is a pre-release and may not be stable for production use.
Get Started with Microsoft Agent Framework A2A
Please install this package via pip:
pip install agent-framework-a2a --pre
A2A Agent Integration
The A2A agent integration enables communication with remote A2A-compliant agents using the standardized A2A protocol. This allows your Agent Framework applications to connect to agents running on different platforms, languages, or services.
A2AAgent (Client)
The A2AAgent class is a client that wraps an A2A Client to connect the Agent Framework with external A2A-compliant agents.
from agent_framework.a2a import A2AAgent
# Connect to a remote A2A agent
a2a_agent = A2AAgent(url="http://remote-agent/a2a")
response = await a2a_agent.run("Hello!")
A2AExecutor (Hosting)
The A2AExecutor class bridges local AI agents built with the agent_framework library to the A2A protocol, allowing them to be hosted and accessed by other A2A-compliant clients.
from agent_framework.a2a import A2AExecutor
from a2a.server.apps import A2AStarletteApplication
from a2a.server.request_handlers import DefaultRequestHandler
from a2a.server.tasks import InMemoryTaskStore
# Create an A2A executor for your agent
executor = A2AExecutor(agent=my_agent)
# Set up the request handler and server application
request_handler = DefaultRequestHandler(
agent_executor=executor,
task_store=InMemoryTaskStore(),
)
app = A2AStarletteApplication(
agent_card=my_agent_card,
http_handler=request_handler,
).build()
Basic Usage Example
See the A2A agent examples which demonstrate:
- Connecting to remote A2A agents
- Hosting local agents via A2A protocol
- Sending messages and receiving responses
- Handling different content types (text, files, data)
- Streaming responses and real-time interaction
Metadata
Release files for agent-framework-a2a 1.0.0b260521
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| agent_framework_a2a-1.0.0b260521.tar.gz | 15.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| agent_framework_a2a-1.0.0b260521-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 30.4 kB
Release files / agent_framework_a2a-1.0.0b260521.tar.gz
| Download URL | agent_framework_a2a-1.0.0b260521.tar.gz |
|---|---|
| Size | 15.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
df6449daf5ced4418bfb24150e481c5ee9d066712423cf40963c121438a47881
|
|
BLAKE2b-256 checksum How to use checksums |
e6da5af4668bd6034125c8d4e10c76f3cb7d9a457d3dccadd0f1e723679a1431
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / agent_framework_a2a-1.0.0b260521-py3-none-any.whl
| Download URL | agent_framework_a2a-1.0.0b260521-py3-none-any.whl |
|---|---|
| Size | 15.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e79b17a8e0ab7d0dccef85ec381d839a6bed028e7ca1ecb76ea9fc23fafe2cd6
|
|
BLAKE2b-256 checksum How to use checksums |
7cca88518d801829f0f997e5c0fecd898b1be872a52c3d08c5c4f5cf18966234
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|