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

# Web search

> Add web search to AI tools through MCP.

Web search MCP provides the `web_search` tool, helping AI tools access information on the web during coding.

## Tool description

> [accordion] web\_search
>
> Performs web searches based on search queries, returning search results and related suggestions.
>
> | Parameter | Type | Required | Description |
> | :- | :- | :-: | :- |
> | query | string | ✓ | Search query |

## Prerequisites

**1. Get your M Plan API key**

Use your M Plan API key.

**2. Install uvx**

```bash macOS / Linux theme={null}
curl -LsSf https://astral.sh/uv/install.sh | sh
```

```powershell Windows theme={null}
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
```

> [!NOTE]
>
> For other installation methods, refer to the [uv repository](https://github.com/astral-sh/uv).

**3. Verify installation**

```bash macOS / Linux theme={null}
which uvx
```

```powershell Windows theme={null}
(Get-Command uvx).source
```

> [!NOTE]
>
> If installed correctly, a path will be shown (e.g., `/usr/local/bin/uvx`). If you get `spawn uvx ENOENT` error, you need to configure the absolute path.

## Use in Claude Code

**1. Download Claude Code**

Download and install Claude Code from [Claude Code website](https://www.claude.com/product/claude-code).

**2. Configure MCP**

> [tab] Quick install
>
> Replace `api_key` with your M Plan API key, then run the following command in your terminal:
>
> ```bash theme={null}
> claude mcp add -s user MiniMax --env MINIMAX_API_KEY=api_key --env MINIMAX_API_HOST=https://api.minimax.io -- uvx minimax-coding-plan-mcp
> ```

> [tab] Manual configuration
>
> Add the following MCP configuration to `~/.claude.json`, replacing the `MINIMAX_API_KEY` placeholder value with your M Plan API key:
>
> ```json theme={null}
> {
>   "mcpServers": {
>     "MiniMax": {
>       "command": "uvx",
>       "args": ["minimax-coding-plan-mcp"],
>       "env": {
>         "MINIMAX_API_KEY": "MINIMAX_API_KEY",
>         "MINIMAX_API_HOST": "https://api.minimax.io"
>       }
>     }
>   }
> }
> ```

**3. Verify configuration**

In Claude Code, run `/mcp`. If you can see `web_search`, the configuration is successful.

![](https://filecdn.minimax.chat/public/59a2ac4d-fe8a-42d9-8898-e81aea641622.png)

## Use in Cursor

**1. Download Cursor**

Download and install Cursor from [Cursor website](https://cursor.com/).

**2. Open MCP configuration**

Open `Customize -> MCPs`, then click `New` to create an MCP server.

![Create an MCP server in Cursor](https://file.cdn.minimax.io/public/agent-tool/mcp/cursor-entry/20260904-143832.png)

**3. Add configuration**

Add the following MCP configuration to `mcp.json`, replacing `Enter your M Plan API key` with your M Plan API key:

```json theme={null}
{
  "mcpServers": {
    "MiniMax": {
      "command": "uvx",
      "args": ["minimax-coding-plan-mcp"],
      "env": {
        "MINIMAX_API_KEY": "Enter your M Plan API key",
        "MINIMAX_API_HOST": "https://api.minimax.io"
      }
    }
  }
}
```

## Use in OpenCode

**1. Download OpenCode**

Download and install OpenCode from [OpenCode website](https://opencode.ai/).

**2. Configure MCP**

Add the following MCP configuration to `~/.config/opencode/opencode.json`, replacing the `MINIMAX_API_KEY` placeholder value with your M Plan API key:

```json theme={null}
{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "MiniMax": {
      "type": "local",
      "command": ["uvx", "minimax-coding-plan-mcp"],
      "environment": {
        "MINIMAX_API_KEY": "MINIMAX_API_KEY",
        "MINIMAX_API_HOST": "https://api.minimax.io"
      },
      "enabled": true
    }
  }
}
```

**3. Verify configuration**

In OpenCode, run `/mcp`. If you can see `MiniMax connected`, the configuration is successful.

![](https://filecdn.minimax.chat/public/1a24c300-4cff-40ee-a428-869467074c1d.png)
