# OpenSERP MCP server

> Performs live searches across six major engines and extracts webpage content as Markdown for AI agents.

- Repository: https://github.com/openserpapi/mcp
- Page: https://hostedmcp.org/servers/openserpapi/mcp
- Transport: stdio
- Stars: 3
- License: MIT
- Latest version: 0.1.12

## Install

### Claude Code

```sh
claude mcp add --env 'OPENSERP_API_KEY=<YOUR_OPENSERP_API_KEY>' mcp -- npx -y @openserp/mcp
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@openserp/mcp"
      ],
      "env": {
        "OPENSERP_API_KEY": "<YOUR_OPENSERP_API_KEY>"
      }
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@openserp/mcp"
      ],
      "env": {
        "OPENSERP_API_KEY": "<YOUR_OPENSERP_API_KEY>"
      }
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"mcp","type":"stdio","command":"npx","args":["-y","@openserp/mcp"],"env":{"OPENSERP_API_KEY":"<YOUR_OPENSERP_API_KEY>"}}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@openserp/mcp"
      ],
      "env": {
        "OPENSERP_API_KEY": "<YOUR_OPENSERP_API_KEY>"
      }
    }
  }
}
```

### Codex

```sh
codex mcp add mcp --env 'OPENSERP_API_KEY=<YOUR_OPENSERP_API_KEY>' -- npx -y @openserp/mcp
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.mcp]
command = "npx"
args = ["-y", "@openserp/mcp"]

[mcp_servers.mcp.env]
OPENSERP_API_KEY = "<YOUR_OPENSERP_API_KEY>"
```

### Gemini CLI

```sh
gemini mcp add -s user -e 'OPENSERP_API_KEY=<YOUR_OPENSERP_API_KEY>' mcp npx -- -y @openserp/mcp
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@openserp/mcp"
      ],
      "env": {
        "OPENSERP_API_KEY": "<YOUR_OPENSERP_API_KEY>"
      }
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `OPENSERP_API_KEY` | no | yes | OpenSERP Cloud API key. Leave unset to use a self-hosted OpenSERP server (http://localhost:7000 by default). |
| `OPENSERP_BASE_URL` | no | no | OpenSERP API base URL, for a self-hosted server on another host or port. |

## Tools (10)

- `search`
- `any_search`
- `fast_search`
- `mega_search`
- `image_search`
- `mega_image`
- `extract`
- `batch_extract`
- `list_engines`
- `get_usage`

## FAQ

### Can I extract content from multiple pages at once?

Yes, the batch_extract tool allows you to read up to 20 pages in a single call.

### How does the server handle long web pages?

The extraction tools truncate long pages to fit an agent's context, limiting content to 20,000 characters per page or 40,000 shared across a batch.

### Which search engines are supported?

The server supports Google, Bing, Yandex, Baidu, DuckDuckGo, and Ecosia.
