# Function dispatchToolCall

- dispatchToolCall(name: string, args: unknown): Promise<ToolResult>

  Dispatches a tool call to the registered handler.

  Feed tool calls are automatically tracked by the feedHealthTracker so that the `get_server_health` tool can report per-feed availability without making upstream API calls. Both thrown errors and in-band "unavailable" envelopes carrying an operational `errorCode` (e.g. `UPSTREAM_TIMEOUT`, `UPSTREAM_ERROR`, `RATE_LIMIT`, `ENRICHMENT_FAILED`) are recorded as failures; `NOT_FOUND` and empty-but-healthy responses are recorded as successes.

  #### Parameters

  - name: string

    Tool name from the MCP `CallTool` request

  - args: unknown

    Validated tool arguments

  #### Returns Promise<ToolResult>

  Tool execution result

  #### Throws

  If the tool name is not recognized

  - Defined in server/toolRegistry.ts:334