launch

Launch all agents as a single API endpoint (HTTP) or an MCP server.

Method

</div>

This is a method of the Agents class in the agents module.

Launch all agents as a single API endpoint (HTTP) or an MCP server. In HTTP mode, the endpoint accepts a query and processes it through all agents in sequence. In MCP mode, an MCP server is started, exposing a tool to run the agent workflow.

Signature

python
def launch(path: str, port: int, host: str, debug: bool, protocol: str) -> Any

Parameters

ParamField str

API endpoint path (default: ‘/agents’) for HTTP, or base path for MCP.

ParamField int

Server port (default: 8000)

ParamField str

Server host (default: ‘127.0.0.1’)

ParamField bool

Enable debug mode for uvicorn (default: False)

ParamField str

“http” to launch as FastAPI, “mcp” to launch as MCP server.

Returns

ResponseField Any

None