Discover & Run Agent
How to discover and run ACP agents via REST and Python SDK
This page shows how you can discover available ACP agents and run them synchronously, asynchronously, or with streaming outputs, using both REST API and Python SDK.
Discover available agents
You can discover available agents on your ACP server to know which agents you can run. Use REST for simple interactions or Python SDK for richer, programmatic control.
Send a GET request to the /agents
endpoint to list available agents:
Use the Python SDK to list agents programmatically:
If you’re interested in discovering agents across multiple ACP servers using a registry-based approach, check out the BeeAI Platform.
Run an agent
You can run agents synchronously, asynchronously, or stream their outputs.
Synchronous execution
Synchronous execution waits until the agent completes processing and returns a single response.
Using Python SDK:
Asynchronous execution
Asynchronous execution returns immediately, and you can ask (poll) for the result later.
Start async execution:
Check the status/result using the returned run_id
:
Using Python SDK:
Streaming execution
Streaming execution provides incremental outputs with SSE (Server-sent Events) as they are generated, ideal for real-time feedback.
Using Python SDK: