MCP server that exposes Grok Build CLI's built-in web_search as an MCP tool
Wellknown found it in public sources; nobody has proven control of it yet. Claiming takes one click if the repository is under your GitHub account, or a small file on your domain otherwise. Verified owners get the badge, 15-minute checks, status alerts, edits that outrank crawled data, and a ranking boost.
Agents can do it too: POST https://wellknown.network/api/v1/claims with {"agent":"mcp-grok-websearch","method":"well_known_file"} — machine-readable steps at claim.json, guide at /docs/claim.
Everything here was measured by our prober or read from a registry. Nothing is self-reported.
Attributed to the source that supplied each field. Treated as claims, not facts.
# mcp-grok-websearch An MCP server that exposes [Grok Build CLI](https://x.ai/cli)'s built-in `web_search` as a standard MCP tool. Any MCP-compatible agent (Codex, Claude Desktop, Cursor, etc.) can use it for real-time web search. ## Prerequisites 1. **Grok Build CLI** installed and authenticated: ```bash curl -fsSL https://x.ai/cli/install.sh | bash grok login # OAuth, or set GROK_CODE_XAI_API_KEY below ``` 2. **uv** (for `uvx` usage): https://docs.astral.sh/uv/ ## Usage ### Run directly with uvx (no install needed) ```bash uvx mcp-grok-websearch ``` ### Configure in an MCP-compatible agent Add to your agent's MCP config (e.g. `~/.codex/config.json`, `claude_desktop_config.json`, etc.): ```json { "mcpServers": { "websearch": { "command": "uvx", "args": ["mcp-grok-websearch"] } } } ``` If you use an API key instead of `grok login`: ```json { "mcpServers": { "websearch": { "command": "uvx", "args": ["mcp-grok-websearch"], "env": { "GROK_CODE_XAI_API_KEY": "xai-..." } } } } ``` ## MCP Tool ### `web_search` Search the web in real time using Grok's built-in search capability. | Parameter | Type | Default | Description | |---|---|---|---| | `query` | `str` | required | Search query | | `max_results` | `int` | `5` | Number of results (1–20) | **Returns:** Formatted results, each with `Title`, `URL`, and `Summary`, separated by `---`. **Example result:** ``` Title: Model Context Protocol – Anthropic URL: https://modelcontextprotocol.io Summary: The official site for MCP, the open standard for connecting AI to external tools and data sources. --- Title: MCP GitHub Repository URL: https://github.com/modelcontextprotocol Summary: Source code and SDKs for the Model Context Protocol. --- ``` ## Authentication The server supports two modes, tried in this order: 1. **API key** – set `GROK_CODE_XAI_API_KEY` (or `XAI_API_KEY`) in the environment. 2. **OAuth session** – if no key i…
Mapped onto the structured taxonomy from declared text and observed tool names. Confidence shown for derived entries.
Every source is kept verbatim. Field changes are logged as events.