> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hibonsai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Call Tool

> Execute a tool

## `tools/call`

Execute a tool.

<Callout color="#0A5B3B" icon="circle-alert">
  This endpoint requires authentication. Ensure you have initialized the MCP connection before calling this method.
</Callout>

## Parameters

<ParamField body="name" type="string" required>
  Name of the tool to execute. Use `tools/list` to retrieve available tool names.
</ParamField>

<ParamField body="arguments" type="object" required>
  Arguments to pass to the tool. The structure depends on the tool's `inputSchema`. For `search_offerings`, pass a `question` string containing the search query.
</ParamField>

## Request

<RequestExample>
  ```json theme={null}
  {
    "jsonrpc": "2.0",
    "id": 3,
    "method": "tools/call",
    "params": {
      "name": "search_offerings",
      "arguments": {
        "question": "What humidifiers do you have?"
      }
    }
  }
  ```
</RequestExample>

## Response

<ResponseExample>
  ```json theme={null}
  {
    "jsonrpc": "2.0",
    "id": 3,
    "result": {
      "content": [
        {
          "type": "text",
          "text": "Found 5 offerings for: What humidifiers do you have?"
        }
      ],
      "structuredContent": {
        "view": "search_results",
        "data": {
          "products": [...],
          "search_query": "What humidifiers do you have?",
          "count": 5
        }
      }
    }
  }
  ```
</ResponseExample>

<Callout color="#0A5B3B" icon="circle-alert">
  The `view` field in `structuredContent` specifies the UI view type for rendering the results. The `data` object contains the actual search results and metadata.
</Callout>
