The Agntcy Application SDK provides a unified factory interface for building interoperable, multi-agent components. It defines standard abstractions and interoperability layers that connect Agntcy and open-source transports, protocols, and directories—enabling agents to communicate and coordinate seamlessly.
|
🔌 Semantic Layer
|
🚀 Transport Layer
|
📂 Directory 🕐
|
🔐 Identity 🕐
|
|
🔍 Observability • Built-in Agntcy Observe SDK integration |
|||
# Install via pip
pip install agntcy-app-sdk
# Or use uv for faster installs
uv add agntcy-app-sdk
# Install from source
git clone https://github.com/agntcy/app-sdk.git
pip install -e app-sdkfrom agntcy_app_sdk.factory import AgntcyFactory
factory = AgntcyFactory()
print(factory.registered_protocols()) # ['A2A', 'MCP', 'FastMCP']
print(factory.registered_transports()) # ['SLIM', 'NATS', 'STREAMABLE_HTTP']
print(factory.registered_observability_providers()) # ['ioa_observe']from agntcy_app_sdk.factory import AgntcyFactory
factory = AgntcyFactory()
# Initialize transport
transport = factory.create_transport(
transport="SLIM",
endpoint="http://localhost:46357",
name="org/namespace/agent-foo"
)
# Create and use MCP client
mcp_client = factory.create_client(
"MCP",
agent_topic="my_remote_mcp_server",
transport=transport
)
async with mcp_client as client:
tools = await client.list_tools()
# Your agent logic herefrom agntcy_app_sdk.factory import AgntcyFactory
factory = AgntcyFactory()
transport = factory.create_transport("NATS", "localhost:4222")
# Connect to remote A2A server
client = await factory.create_client(
"A2A",
agent_topic="my_remote_a2a_server",
transport=transport
)📁 src/
└── 📦 agntcy_app_sdk/
├── 🏭 factory.py # Main factory interface
├── 🔄 app_sessions.py # Session management
├── 📂 directory/ # Agent directory services
├── 🔐 identity/ # Authentication & identity
├── 🧠 semantic/ # Semantic layer (SLIM)
├── 🌐 transport/ # Transport implementations
└── 🛠️ common/ # Shared utilities
For a fully functional distributed multi-agent sample app, check out our coffeeAgntcy!
| Component | Version | Description | Repo |
|---|---|---|---|
| SLIM | 0.6.1 |
Secure Low-Latency Interactive Messaging (SLIM) facilitates communication between AI agents using request-reply and moderated group-chat patterns. | Repo |
| Observe SDK | 1.0.24 |
Enables multi-agent observability by setting enable_tracing=True when initializing the AgntcyFactory. This automatically configures tracing and auto-instrumentation for SLIM and A2A. |
Repo |
| Directory | Coming soon | Component for service discovery and directory-based agent lookups. | Repo |
| Identity | Coming soon | Provides agent identity, authentication, and verification mechanisms. | Repo |
The /tests directory contains both unit and end-to-end (E2E) tests for Agntcy components and workflows.
Before running tests, start the required message bus services:
docker-compose -f services/docker/docker-compose.yaml upRun all transports
Run the parameterized E2E test for the A2A client across all supported transports:
uv run pytest tests/e2e/test_a2a.py::test_client -sRun a single transport
To test only a specific transport (e.g. SLIM):
uv run pytest tests/e2e/test_a2a.py::test_client -s -k "SLIM"Broadcast messaging
Run the E2E test for A2A broadcast communication across all transports:
uv run pytest tests/e2e/test_a2a.py::test_broadcast -sGroup chat
Run the E2E test for A2A moderated group-chat using a specific transport (e.g. SLIM):
uv run pytest tests/e2e/test_a2a.py::test_groupchat -s -k "SLIM"Single transport
Run an E2E test for the FastMCP client with a specific transport:
uv run pytest tests/e2e/test_fast_mcp.py::test_client -s -k "SLIM"Contributions are welcome! Please see the contribution guide for details on how to contribute to the Agntcy Application SDK.
Publishing to PyPI is automated via GitHub Actions. To release a new version:
- Update the
versionfield inpyproject.tomlto the desired release version. - Commit this change and merge it into the
mainbranch via a pull request. - Ensure your local
mainis up to date:git checkout main git pull origin main
- Create and push a tag from the latest
maincommit. The tag must be in the formatvX.Y.Zand match thepyproject.tomlversion:git tag -a v0.2.6 -m "Release v0.2.6" git push origin v0.2.6 - The release workflow will validate the tag and version, then publish to PyPI if all checks pass.
Note: Tags must always be created from the main branch and must match the version in pyproject.toml.