UniGrok
UniGrok is a local MCP server that gives coding agents a unified @grok teammate, auto-routing tasks across local models, Grok Build login, or xAI API for chat, agentic work, media, search, and developer utilities.
Unified agent tool (
agent) — run any task with auto-routing, sessions, modes (fast, reasoning, thinking, research), and effort control.Chat and vision — plain chat, vision analysis, file-aware chat, stateful continuations, and server-side stored conversations.
Media generation — create/edit images and videos, extend videos, with URL or base64 output.
Web and X search — real-time web search with domain filters and X post/profile search with date/handle filters.
Remote code execution — run Python in xAI's server-side sandbox without touching the local machine.
Local developer tools — read/list project files, run pytest, inspect git status/diff/log/branches, create branches, apply patches, and commit.
Research jobs — submit deferred multi-agent research tasks and poll/list results.
Memory and sessions — list/get/clear chat sessions, remember/search/forget durable facts, distill sessions into knowledge.
File uploads to xAI — upload, list, fetch metadata/content, and delete files for use in chats.
Model inspection — list live xAI models and detailed local/CLI/.grok profiles.
Server management — health/status, discover self/onboarding info, restart container, and vacuum the SQLite DB.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@UniGrok explain the difference between list and tuple in Python"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
One Grok teammate. Every coding agent.
Install UniGrok Core once, connect every MCP-capable IDE, and use @grok from any
project. Start with a no-key local model, a Grok Build login, an optional xAI API key,
or any combination of those routes.
http://localhost:4765/mcpThis clone, the commands below, and the service they start on port 4765 are the
complete public offering. Private provider coordination and operator infrastructure are
not part of UniGrok Core.
Get running in three minutes
You need Docker Desktop and Git. Choose at least one inference route:
No-key local model — Docker Model Runner plus a compatible local model.
Grok Build login — subscription or available free-tier CLI access.
xAI developer API key (console.x.ai) — optional and metered; adds provider-hosted files, media, search, and code execution.
UniGrok discovers the routes that are actually ready. A local-only installation stays local and reports unsupported cloud-only capabilities honestly.
In a hurry?
npx @djtelicloud/unigrokprints these setup steps in your terminal. (A full launcher that runs the setup for you is planned; today UniGrok installs via Docker, below.)
1. Download and build
git clone https://github.com/djtelicloud/grok-mcp-server.git
cd grok-mcp-server
docker compose build2. Choose an inference route
No paid key or CLI login. Enable Docker Model Runner, pull a pinned Gemma model, and start it locally:
docker desktop enable model-runner
docker model pull ai/gemma3:4B-Q4_K_M
docker model run --detach ai/gemma3:4B-Q4_K_MThis route uses Docker Desktop's private container endpoint and no API key. Leave
host-side TCP support disabled: Docker Model Runner's API is unauthenticated, and
enabling --tcp can expose it beyond localhost on some installations. The pinned
model supplies bounded local text assistance; UniGrok does not pretend that it
provides cloud search, media generation, or a separately certified code role.
Grok Build. Log in once — the device login runs inside the container and stores the session in a private Docker volume:
docker compose run --rm grok-cli-authWant the Grok CLI on your own machine too? It is optional:
curl -fsSL https://x.ai/cli/install.sh | bashxAI API key (optional, metered). Adds provider-hosted files, vision, image/video, search, code execution, and bounded recovery. Keep the key in the service environment only — never in IDE MCP JSON:
export XAI_API_KEY='<your key>'Any one route works alone. Configure more than one if you want bounded, receipted recovery between compatible routes.
3. Start UniGrok
docker compose up -d grok-mcp
curl --fail --silent http://127.0.0.1:4765/readyzYou are ready when the response says "status":"ready". On Windows PowerShell, prefer
curl.exe -fsS http://127.0.0.1:4765/readyz if the curl alias is unreliable.
Multi-step agentic work (Ground pack)
UniGrok’s agent tool is leaf labor. Your IDE or automation remains the orchestrator.
For multi-step work, put a short Mission Brief in task (goal, options, constraints,
done-when, return shape). Retry at most a few times with the same goal and an appended
finding if a try fails. Prefer densified returns: WHAT / WHY / DELTA / NEXT.
Offline / free local path: when subscription or API is unavailable, Core can still use a
staged local model route (Docker Model Runner or loopback OpenAI-compatible runtime).
See Local model routes. Relay resolved_plane and cost
receipts; disable web/X tools for true offline briefs; fail closed for cloud-only media.
Day-1 is this clone plus http://localhost:4765/mcp. No GitHub token and no hosted
MCP URL are required. grok_mcp_onboard_client is optional IDE help (consent first).
Contributors who want the Ground pack after GitHub auth can follow
CONTRIBUTING.md.
Day-1 is Core + Ground pack only (not a second labor Docker seat, not extra
operator nodes). Heavier capacity is a separate maintainer grant when someone runs an
approved extra node under their map.
Official GitHub contributors (optional)
UniGrok can detect whether the authenticated caller is one of your official GitHub
contributors. This never trusts X-Client-ID alone.
Service environment (examples):
# Fast path: explicit allowlist of GitHub logins
export UNIGROK_GITHUB_CONTRIBUTOR_ALLOWLIST='djtelicloud,curtisfratianne'
# And/or live GitHub API checks (service token — never put a user PAT in IDE MCP JSON)
export UNIGROK_GITHUB_TOKEN='ghp_…' # or GITHUB_TOKEN
export UNIGROK_GITHUB_CONTRIBUTOR_REPOS='djtelicloud/grok-mcp-server,your-org/your-other-repo'
export UNIGROK_GITHUB_CONTRIBUTOR_ORGS='your-org'
# Local single-operator bind (optional)
export UNIGROK_GITHUB_LOGIN='djtelicloud'grok_mcp_status and grok_mcp_discover_self return an affiliation object:
is_official_contributor (true/false/null), source, and whether a login was detected.
Use this for soft UX (contributor tips, onboard tone) — not as a secret vault.
Optional local bearer protection is available for /mcp and /v1:
export UNIGROK_LOCAL_MCP_TOKEN="$(python -c 'import secrets; print(secrets.token_urlsafe(32))')"
docker compose up -d --force-recreate grok-mcp
printf '%s\n' "$UNIGROK_LOCAL_MCP_TOKEN"Store that bearer in the IDE's secret-backed MCP header configuration. A SHA-256 digest
can be supplied as UNIGROK_LOCAL_MCP_TOKEN_SHA256 instead of retaining plaintext in
the service environment. Health and readiness endpoints remain unauthenticated.
New to Grok-powered coding? Cursor (referral link) is an easy on-ramp — set up a Grok plane above whenever you're ready.
Related MCP server: Toolport
Connect your IDE
Paste this into Cursor, Claude Code, VS Code, Codex, Antigravity, or any MCP-capable coding agent:
Configure an MCP server named grok for this machine.
- Transport: Streamable HTTP
- URL: http://localhost:4765/mcp
- Send a stable X-Client-ID header for this IDE, such as cursor or claude-code
- When local bearer protection is enabled, send its Authorization header from the IDE's
secret store
- Never place XAI_API_KEY in the IDE configuration; credentials stay in UniGrok
- Reload MCP servers, then call grok_mcp_discover_self
- Use UniGrok's agent tool whenever I say @grokThe config filename varies by IDE, but every client connects to the same local URL.
Try it in 60 seconds
Start a fresh conversation in any project and try:
@grok research the best current approach for this feature, then give me a short plan.@grok remember that this project prefers small modules and tests before refactors.@grok continue session "my-project" and challenge the implementation plan.That is it — type @grok, and UniGrok picks the route, model, effort, and recovery for
you. Every answer comes back with a plane and cost receipt.
Why vibe coders use UniGrok
What you get | |
⚡ | One tool, |
🎚️ | Levels that scale — from a quick answer up to a parallel review swarm, picked for you |
💸 | A real zero-key route — a compatible Docker Model Runner model can serve local text without a paid provider key |
🧾 | Receipts on every answer — plane, cost, route, and fallback, so nothing is hidden |
🧠 | Sessions and memory — named sessions and facts you control, kept locally |
🎨 | Images, video, vision, files, web + X search when you add an API key |
🤖 | PR reviews on comment — a maintainer types |
🔐 | One credential boundary — keys live in UniGrok, not in every project |
What's new in 1.1
Levels that scale with the job
Pass a level when you care how hard Grok thinks:
none→minimal→low→medium→high→xhigh— one call, native Grok effortsmax— a silent deep-reasoning harness under the hoodultra— a parallel hive: draft, persona votes, then a merge
Leave level unset and UniGrok picks the rung for you. In local Compose, unclear tasks
use CLI-first router votes. Hard tasks auto-engage deeper reasoning; a typo fix never
pays for a swarm. Receipts expose
any bounded API fallback used when those votes are inconclusive.
Jobs that survive restarts
On persistent local Compose, Mission V2 tasks keep their mission ledger across service restarts and resume with the
same continue_token; terminal reattach returns the durable winner without rerunning
the model. Generic durable jobs keep results recorded before restart. If a generic job
was interrupted before a result was recorded, it returns lost: the provider outcome
is unknown, so inspect state before retrying a metered or mutating operation.
Three routes, one simple entry point
The normal @grok service discovers a compatible local runtime automatically. It
prefers a ready Grok Build login, can use a service-owned API key when authorized, and
uses the local route when remote routes are unavailable. See
Local model routes for the integrated route and the
optional named helper.
flowchart TD
T["{ task: Your request }"] --> R["Live route discovery"]
R -->|"no-key local"| G["Local Gemma route"]
R -->|"Grok Build ready"| D["Subscription / free-tier work"]
R -->|"API explicitly configured"| M["Metered specialists"]
G --> O["Result + model / plane / cost receipt"]
D --> O
M --> Oagentmakes web, X search, and code tools available when the selected route supports them.A ready Grok Build login remains the preferred remote lead.
With no remote credential, a compatible local runtime provides bounded local text help at
cost_usd: 0.UniGrok selects models, planes, reasoning effort, and recovery automatically.
Clear tasks route heuristically; otherwise three bounded, CLI-first intent votes select shape. If too few votes parse, an API semantic fallback may run (256 output tokens by default, configurable from 64–1024). Direct work remains subscription-first; specialists and bounded recovery use API as needed.
Supplying
XAI_API_KEYis the service owner's opt-in to API use.Set
UNIGROK_ENABLE_METERED_API=falsefor an immediate API kill switch.
Install once, keep projects clean
UniGrok is a global local service. It does not copy itself into every repository and it never receives hidden access to your workspace.
On first use, UniGrok can offer an optional host-native integration pack through
grok_mcp_onboard_client:
MCP connects → install globally? → IDE previews owned files → user approves → reload
↓
project guidance still overrides itGlobal is recommended: install a namespaced skill/plugin in the IDE's user scope.
Project creates only a plan for project-local guidance.
Not now and Never ask again are explicit choices.
UniGrok never writes these files itself. The calling IDE uses its normal permissions, shows conflicts, and must not overwrite user-modified files blindly.
The current project-guidance conventions are:
AGENTS.md
.agents/rules/<rule-name>.md
.agents/workflows/<workflow-name>.md
.agents/skills/<skill-name>/SKILL.mdProject customizations take priority over the global UniGrok baseline. UniGrok provides the instructions and templates but remains workspace-neutral.
Safe by design
The service binds to
127.0.0.1by default.Optional local bearer authentication protects
/mcpand/v1, accepts direct loopback/private-container peers, rejects forwarding headers, and bounds failure state.CLI OAuth and the xAI API key stay on the server side.
The CLI runs in an empty disposable workspace with local file, shell, Git, edit, external MCP, memory, and subagent access disabled.
Project text reaches Grok only when the calling IDE deliberately sends bounded
workspace_context.Local durable payloads are recursively secret-redacted before SQLite storage. Mission answer projections are additionally capped at 100 KB.
Named-session turns and context packs are written only after Mission V2 CommitDone; rejected drafts never enter session memory, and repeated terminal reattach is idempotent.
In persistent local Compose, terminal runtime rows default to 24-hour retention (configurable 1–720 hours), while named sessions and remembered facts persist until explicitly deleted. Hosted state is instance-local as documented below.
Media accepts public HTTPS URLs; uploads accept caller-supplied bytes, never local filesystem paths.
Ask for an image or video without an API key and UniGrok says so plainly — it never fabricates a media link.
See SECURITY.md for the complete public runtime boundary.
Go deeper when you need it
I want to… | Read |
Understand the service and state machines | |
See every tool and routing rule | |
Use the integrated local route or named local helper | |
Drive | |
Auth with GitHub, then install the public Ground pack | |
Develop or acceptance-test UniGrok | |
See what has limited soak and how to report a miss | |
See what changed between versions | |
Report a security issue |
License
Available Tools
47 toolsagentA
Run the unified UniGrok agent on any task. This is the headline entry point — use it by default for anything nontrivial instead of picking a specialized tool.
It auto-routes across Grok models (planning model for reasoning-heavy tasks, coding model otherwise), gives the model its full action space on every request — xAI server-side web search, X search, and sandboxed code execution plus local file, git, and test tools — and lets the model decide for itself whether to act. Pass a session name and it remembers prior turns, including tool observations, so multi-step work continues across calls. When the client requests progress (MCP progressToken), depth and tool progress is reported live via the injected FastMCP context.
Args:
task: The goal, question, or task for the agent.
session: Optional session name. Persists conversation history and tool
traces so later calls can continue the work.
mode: "auto" (default) self-routes; "fast" forces a single toolless
completion for trivial prompts; "reasoning" pins the planning
model; "thinking" runs the agent loop plus a schema-enforced
reflection review for the hardest tasks (slowest, most expensive);
"research" runs multi-agent research on the planning model
(agent_count from UNIGROK_RESEARCH_AGENT_COUNT, 4 or 16) with
inline citations requested — sources come back under citations.
model: Optional Grok model id. Leave unset to let routing choose.
require_reasoning_level: Minimum required Grok reasoning level (low, medium, high).
Returns: AgentResult containing execution metadata and responses.
Inputs: task (required), mode, model, session, +1 more. Returns: why, text, model, plane, +11 more
chatA
Send a text prompt to a Grok model and return its reply.
Absorbs the old agentic_chat tool: the ReAct AgentLoop is now the
default route, so the model has its tool surface and self-directs.
Set enable_agentic=False to force a single toolless completion.
Args:
prompt: User message to send to the model.
session: Optional session name. Persists conversation history.
model: Grok model id (defaults to grok-build-0.1).
system_prompt: Optional system instruction prepended to the conversation.
agent_count: 4 or 16. Only valid with grok-4.20-multi-agent.
enable_agentic: If True (default), runs through the ReAct AgentLoop.
require_reasoning_level: Minimum required Grok reasoning level (low, medium, high).
Inputs: prompt (required), model, session, agent_count, +3 more. Returns: text, model, plane, route, +10 more
chat_with_filesA
Chat with Grok using one or more previously uploaded files as context.
Args:
prompt: Question or instruction about the attached files.
file_ids: IDs returned by xai_upload_file.
session: Optional session name for persistent local history.
model: Grok model id (default grok-4.3).
system_prompt: Optional system instruction prepended to the conversation.
Inputs: prompt (required), file_ids (required), model, session, +1 more. Returns: text, model, plane, route, +10 more
chat_with_visionA
Analyze one or more images with a Grok vision model.
Args:
prompt: Question or instruction about the image(s).
session: Optional session name for persistent history in chats.
model: Vision-capable Grok model (default grok-4.3).
image_paths: Local image file paths to analyze.
image_urls: Public image URLs to analyze.
detail: Image detail level. One of "auto", "low", or "high".
Inputs: prompt (required), model, detail, session, +2 more. Returns: text, model, plane, route, +10 more
clear_chat_historyADestructive
Delete the history mapping and cascades messages for a chat session.
Inputs: session. Returns: result
db_vacuumADestructive
Perform database compacting and optimization (VACUUM).
Inputs: no named parameters. Returns: result
delete_stateful_responseADestructive
Delete a stored chat completion from xAI's servers.
Args: response_id: ID of the stored response to remove.
Inputs: response_id (required). Returns: result
distill_sessionA
Distill a chat session's stored history into durable knowledge facts.
Submits a background job (same lifecycle as research jobs — poll
get_research_job(job_id)) that summarizes the session into 3-8
standalone facts on the cheap coding model and saves them to the
knowledge memory with source='session:'.
Args: session: Name of a stored chat session.
Inputs: session (required). Returns: result
extend_videoA
Extend an existing video with a follow-up prompt.
Args:
prompt: What should happen in the extended segment.
video_url: Public URL of the source video (.mp4, 2–15 s).
model: Video model (default grok-imagine-video).
duration: Length of the extension in seconds (2–10, default 6).
Inputs: prompt (required), video_url (required), model, duration. Returns: text, model, plane, route, +13 more
forget_factADestructive
Permanently delete one fact from the workspace knowledge memory.
Args:
fact_id: The id returned by remember_fact or search_knowledge.
Inputs: fact_id (required). Returns: result
generate_imageA
Generate new images or edit existing ones with Grok Imagine.
Args:
prompt: Image description or edit instruction.
model: Image model (grok-imagine-image or grok-imagine-image-pro).
image_paths: Local image files used as edit sources or references.
image_urls: Public image URLs used as edit sources or references.
n: Number of images to generate (1–10).
image_format: "url" (default) or "base64".
aspect_ratio: Aspect ratio like "16:9", "1:1", or "9:16".
resolution: "1k" or "2k".
Returns: MediaResult containing image metadata and URLs.
Inputs: prompt (required), n, model, image_urls, +4 more. Returns: text, model, plane, route, +13 more
generate_videoA
Generate or edit videos with Grok Imagine.
Args:
prompt: Video description, or the edit instruction for video editing.
model: Video model (default grok-imagine-video).
image_path: Local image to use as the starting frame.
image_url: Public image URL to use as the starting frame.
video_path: Local video to edit (max 20 MB, .mp4, ≤ 8.7s).
video_url: Public video URL to edit (.mp4, ≤ 8.7s).
reference_image_paths: Local images used as style/subject references.
reference_image_urls: Public image URLs used as style/subject references.
duration: Video length in seconds (1–15, ignored when editing).
aspect_ratio: Aspect ratio like "16:9" or "9:16".
resolution: "480p" or "720p".
Inputs: prompt (required), model, duration, image_url, +7 more. Returns: text, model, plane, route, +13 more
get_chat_historyBRead-only
Return the most recent messages for a local chat session from SQLite.
Inputs: limit, session. Returns: result
get_research_jobARead-only
Fetch the status and result of a deferred research job.
Statuses: queued/running (in flight), done (result and cost_usd
present), error (error present), not_found, or stale — a
queued/running job whose updated_at is older than
UNIGROK_JOB_TIMEOUT_SEC, meaning the task that owned it did not survive a
server restart and the job will never finish on its own.
Args:
job_id: ID returned by submit_research_job.
Inputs: job_id (required). Returns: result
git_apply_patchBDestructive
Apply a unified diff patch. Requires local git write mode.
Inputs: patch (required), repo_path. Returns: result
git_commitADestructive
Commit explicit paths only. Requires local git write mode.
Inputs: paths (required), message (required), repo_path. Returns: result
git_create_branchB
Create and switch to a new branch. Requires local git write mode.
Inputs: branch_name (required), repo_path. Returns: result
git_current_branchBRead-only
Return the active branch name.
Inputs: repo_path. Returns: result
git_diffBRead-only
Return the current git diff, optionally for staged changes or one path.
Inputs: path, cached, repo_path. Returns: result
git_logBRead-only
Return a short one-line git history.
Inputs: limit, repo_path. Returns: result
git_showBRead-only
Return git show for a validated commit-ish ref.
Inputs: commit, repo_path. Returns: result
git_statusBRead-only
Return git status --porcelain for the current repository.
Inputs: repo_path. Returns: result
grok_agentA
Unified @grok Entry Point: run the thinking route — the ReAct AgentLoop wrapped in a schema-enforced reflection loop — with explicit retry and budget caps.
Args:
prompt: Task or question for the agent.
session: Optional session name for persistent history in chats.
model: Grok model id (default grok-4.3).
system_prompt: Optional system instruction prepended to the conversation.
max_iterations: Strict cap on reviewer-driven correction retries (default 5).
cost_limit: Total budget in USD before hard abort (default 0.50).
Inputs: prompt (required), model, session, cost_limit, +2 more. Returns: why, text, model, plane, +11 more
grok_mcp_discover_selfARead-only
Exposes OKF bundle information, WebMCP manifests, and tool schemas for zero-configuration agent onboarding.
Inputs: no named parameters. Returns: data, text, model, plane, +9 more
grok_mcp_restart_containerADestructive
Safely restart the UniGrok Docker container by executing docker compose up --build -d. Only works if running in a context where docker compose is available and enabled.
Inputs: no named parameters. Returns: data, text, model, plane, +9 more
grok_mcp_statusARead-only
Inspect the current health, versions, CLI auth, and sqlite metrics of the Grok-MCP server.
Inputs: no named parameters. Returns: result
grok_reflectARead-only
Run a structured, tool-free Grok review of an artifact or plan.
Use this when a client needs a deterministic critique shape rather than a
full agent run. It calls xAI structured outputs through the shared
_parse_structured helper, so the reflection pass cannot invoke local
tools and degrades explicitly if structured parsing is unavailable.
Inputs: subject (required), model, context, criteria. Returns: ok, text, model, plane, +10 more
list_chat_sessionsARead-only
List all chat sessions stored under the SQLite session store.
Inputs: no named parameters. Returns: result
list_modelsARead-only
List live xAI API model IDs. Lightweight, direct, and fast.
Inputs: no named parameters. Returns: result
list_models_detailedARead-only
List xAI API models, local Grok CLI models, and .grok model profiles separately.
Inputs: no named parameters. Returns: result
list_project_filesCRead-only
List source code and config files present in the current workspace.
Inputs: extensions, max_results. Returns: result
list_research_jobsARead-only
List the most recent deferred research jobs, newest first.
Args: limit: Maximum number of jobs to return (clamped to 1-100, default 20).
Inputs: limit. Returns: result
read_local_fileBRead-only
Read a local project workspace file for code context or diagnostics.
Inputs: file_path (required), max_chars. Returns: result
remember_factA
Save one durable fact to the local workspace knowledge memory.
Facts are distilled knowledge — decisions, constraints, preferences, verified findings — injected as hints into future prompts that match them. Saving an identical fact again touches the existing row instead of duplicating it.
Args: fact: One self-contained sentence with concrete specifics. scope: 'global' (default, injected everywhere) or a session name for session-scoped knowledge.
Inputs: fact (required), scope. Returns: result
remote_code_executionB
Solve a task by letting Grok write and run Python in xAI's server-side sandbox.
Renamed from code_executor — it invokes xAI's remote code_execution
tool; no code runs on this machine.
Inputs: prompt (required), max_turns. Returns: data, text, model, plane, +9 more
retrieve_stateful_responseARead-only
Fetch a stored chat completion from xAI by its response ID.
Args:
response_id: ID returned by a prior stateful_chat call.
Inputs: response_id (required). Returns: result
run_local_testsC
Run local pytest verification without exposing arbitrary shell execution.
Inputs: target, max_seconds, max_output_chars. Returns: result
search_knowledgeARead-only
Search the workspace knowledge memory for facts matching a query.
Local results are ranked by FTS5 bm25 when available (term-overlap otherwise). With UNIGROK_COLLECTIONS=1 and a capable SDK, matches from the xAI knowledge collection are merged in (origin='collection').
Args: query: Search terms. limit: Maximum number of local facts to return (1-25, default 5).
Inputs: query (required), limit. Returns: result
stateful_chatA
Continue a server-side stored conversation using xAI's stateful chat.
Args:
prompt: User message to append.
model: Grok model id (default grok-4.3).
response_id: ID of the previous response to continue from.
system_prompt: Optional system instruction.
Returns: ChatResult containing execution metadata and responses.
Inputs: prompt (required), model, response_id, system_prompt. Returns: text, model, plane, route, +10 more
submit_research_jobA
Submit a long-running research task as a deferred xAI job and return
immediately. The job runs in the background with xAI's server-side web
search, X search, and code-execution tools attached; poll
get_research_job(job_id) for the result.
Args: prompt: The research question or task. model: Optional Grok model id. Leave unset to use the planning model. agent_count: Optional multi-agent fan-out — only 4 or 16 are accepted.
Returns:
A dict with job_id (pass it to get_research_job), status
("queued"), and the resolved model.
Inputs: prompt (required), model, agent_count. Returns: result
web_searchARead-only
Query the web using xAI's real-time web search tool.
Args:
prompt: The research question or search instruction.
allowed_domains: Restrict search to these domains (e.g. ["arxiv.org"]).
excluded_domains: Domains to exclude from search results.
Inputs: prompt (required), allowed_domains, excluded_domains. Returns: data, text, model, plane, +9 more
xai_delete_fileBDestructive
Delete an uploaded file from xAI.
Inputs: file_id (required). Returns: result
xai_get_fileCRead-only
Retrieve metadata of a file uploaded to xAI.
Inputs: file_id (required). Returns: result
xai_get_file_contentARead-only
Download the raw content of an uploaded file from xAI.
Inputs: file_id (required), max_bytes. Returns: result
xai_list_filesARead-only
List all files uploaded to xAI from this account.
Inputs: no named parameters. Returns: result
xai_upload_fileA
Upload a local project file to xAI's servers so it can be reference-attached in chats.
Returns:
A dict with file_id (pass it to chat_with_files/xai_get_file_content),
filename, size_bytes, and a human-readable summary.
Inputs: file_path (required). Returns: result
x_searchARead-only
Query X posts and profiles using xAI's real-time X search tool.
Args:
prompt: The search question or instruction.
allowed_x_handles: Restrict search to posts from these X handles.
from_date: Earliest post date, ISO format (e.g. "2026-06-01").
to_date: Latest post date, ISO format (e.g. "2026-07-01").
Inputs: prompt (required), to_date, from_date, allowed_x_handles. Returns: data, text, model, plane, +9 more
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 47 tools
Many tools have overlapping purposes, such as multiple chat/agent tools (`agent`, `chat`, `grok_agent`, `stateful_chat`) and multiple model listing tools (`list_models`, `list_models_detailed`). While descriptions attempt to differentiate, the overlap is significant and would likely cause misselection.
Tool names are inconsistent in style: some are short single words (`agent`, `chat`), while others use long snake_case phrases (`grok_mcp_discover_self`, `remote_code_execution`). No clear pattern emerges, mixing verbs and nouns.
47 tools is excessively high for a single MCP server. While the server covers many domains (chat, git, knowledge, media, etc.), the tool set would be more coherent if split into specialized servers. The count feels unwieldy.
The server covers a wide range of functionality including chat, agent, file management, web/X search, code execution, research jobs, knowledge memory, git operations, and media generation. Minor gaps exist (e.g., missing git push/pull, knowledge update), but overall it is fairly complete for its domain.
Maintenance
Related MCP Connectors
LLM cost optimization gateway, repo token-waste auditor & model arbitrage MCP server.
Shared memory MCP server for Claude Code, Codex, Gemini CLI and Cursor. Cited, editable.
Agent Cost Allocator MCP — multi-tenant LLM cost attribution for chargeback billing. Companion to
A full backend your AI coding agent can set up over MCP
Related MCP Servers
- AlicenseAqualityBmaintenanceUse XAI's latest api functionalities with Grok MCP. It supports image understanding and generation, live search, latest models and more.2255MIT
- AlicenseAqualityAmaintenanceOne local gateway for all your MCP servers — shared by every AI coding tool (Claude, Cursor, VS Code, Codex). Set up each server once; keys stay in the OS keychain; lazy discovery keeps agent context small. Local-first, open source.4241MIT
- AlicenseAqualityCmaintenanceA minimal local MCP server that lets Claude Desktop or Claude Code delegate coding tasks to Grok Build running headless as a subagent.51MIT
- AlicenseAqualityDmaintenanceMCP server for integrating xAI's Grok model into OpenAI Codex Desktop/GUI, enabling direct Grok calls via chat completions or responses with OAuth or API key authentication.9MIT