Skip to content

API Reference

function createHub(config: HubConfig): Hub;

Create a Hub instance.

async start(): Promise<void>

Start the hub.

async listTools(): Promise<Tool[]>

List available tools (aggregated).

async function startServer(options: ServerOptions): Promise<void>;

Start the MCP hub server (STDIO/HTTP).

Returns a JSON snapshot of currently connected servers. Fields include id, status, type, and arrays of tools, resources, and prompts.