Metadata-Version: 2.4
Name: dapparena-agent-sdk
Version: 0.1.0
Summary: Dapp Arena Agent SDK — Build and deploy AI agents on Dapp Arena marketplace
Project-URL: Homepage, https://dapparena.io
Project-URL: Documentation, https://docs.dapparena.io
Project-URL: Repository, https://github.com/dapparena/agent-sdk-python
Author-email: Dapp Arena <dev@dapparena.io>
License-Expression: MIT
Keywords: agent,ai,blockchain,dapparena,worldland
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.10
Requires-Dist: fastapi>=0.110.0
Requires-Dist: httpx>=0.27.0
Requires-Dist: pydantic>=2.5.0
Requires-Dist: uvicorn[standard]>=0.27.0
Requires-Dist: websockets>=12.0
Provides-Extra: all
Requires-Dist: web3>=6.0.0; extra == 'all'
Provides-Extra: web3
Requires-Dist: web3>=6.0.0; extra == 'web3'
Description-Content-Type: text/markdown

# Dapp Arena Agent SDK (Python)

> Build and deploy AI agents on the Dapp Arena marketplace.

## Quick Start

```bash
pip install dapparena-agent-sdk
```

```python
from dapparena import BaseAgent, AgentServer

class MyAgent(BaseAgent):
    def __init__(self):
        super().__init__(
            name="MyAgent",
            name_ko="내 에이전트",
            description="A helpful assistant",
        )

    async def chat(self, message: str, context: dict | None = None) -> str:
        return f"Hello! You said: {message}"

# Run the agent server
AgentServer(MyAgent(), port=8080).run()
```

## A2A Protocol Endpoints

| Endpoint | Method | Description |
|----------|--------|-------------|
| `/health` | GET | Health check |
| `/a2a/capabilities` | GET | Agent capabilities |
| `/a2a/info` | GET | Agent metadata |
| `/a2a/chat` | POST | Synchronous chat |
| `/a2a/stream` | POST (SSE) | Streaming chat |
| `/a2a/quote` | POST | Quote generation |
| `/a2a/ws` | WebSocket | WebSocket chat |

## Calling Other Agents

```python
from dapparena import A2AClient

client = A2AClient()
response = await client.chat("http://other-agent:8080", "Analyze this")
```

## License

MIT
