pypi mcp-grokstreamable-httpMITupdated 11d ago
A Model Context Protocol (MCP) server for Grok (xAI) — chat/reasoning/vision and Grok Imagine video generation, powered by the AceDataCloud API.
What can you do with mcp grok?
GrokMCP
A Model Context Protocol (MCP) server for Grok (xAI) — chat/reasoning/vision and Grok Imagine video generation, powered by the AceDataCloud API.
Chat with Grok models, or generate short AI videos from a text prompt or a still image — directly from any MCP-compatible client (Claude Desktop, Claude Code, Cursor, etc.).
Features
- Chat / Reasoning / Vision — Talk to Grok 4.5 / Grok 4 / Grok 3 models, with image input and tool calling
- Text to Video — Generate a video clip from a text description
- Image to Video — Animate a reference image into a video
- Async task tracking — Submit a job, poll for the result, single or batch
- stdio & HTTP transports — Local stdio for desktop clients, HTTP for remote hosting
Tools
| Tool | Description |
|---|---|
grok_chat_completions |
Chat completion (reasoning / vision / tool calling) with Grok chat models. |
grok_text_to_video |
Generate a video from a text prompt (any model except grok-imagine-video-1.5:official). |
grok_image_to_video |
Generate a video from an input image (+ optional motion prompt). |
grok_get_task |
Query the status/result of a single generation task. |
grok_get_tasks_batch |
Query the status/result of multiple tasks at once. |
grok_list_models |
List available models and their capabilities. |
grok_list_actions |
List all tools and example workflows. |
grok_get_prompt_guide |
Tips for writing effective video prompts. |
Models
Chat (grok_chat_completions)
| Model | Notes |
|---|---|
grok-4.5 |
Default — latest flagship reasoning model |
grok-4 |
Previous flagship reasoning model |
grok-3 |
Earlier-generation model |
Video
| Model | Text→Video | Image→Video | Notes |
|---|---|---|---|
grok-imagine-video-1.5-fast:reverse |
✅ | ✅ | Default. Fastest & cheapest. 6-30s, duration-banded billing. |
grok-imagine-video:reverse |
✅ | ✅ | Standard. 1-15s, billed per output second. |
grok-imagine-video:official |
✅ | ✅ | Official endpoint, higher fidelity. 1-15s, per second. |
grok-imagine-video-1.5:official |
❌ | ✅ | Official image-to-video only (requires image_url). Up to 1080p, per second. |
Parameters
| Parameter | Applies to | Values |
|---|---|---|
prompt |
both | Text description (required for text-to-video) |
image_url |
image-to-video | Input image URL (required for -1.5-preview) |
reference_image_urls |
image-to-video | Optional list of style/content reference images |
aspect_ratio |
both | 1:1, 16:9 (default), 9:16, 4:3, 3:4, 3:2, 2:3 |
resolution |
both | 480p (default), 720p, 1080p |
duration |
both | grok-imagine-video-1.5-fast:reverse: 6–30s; other models: 1–15s (default 6) |
callback_url |
both | Optional async webhook |
Installation
Via uvx (recommended)
uvx mcp-grok
Via pip
pip install mcp-grok
mcp-grok
Configuration
Set your AceDataCloud API token (get one at https://platform.acedata.cloud):
export ACEDATACLOUD_API_TOKEN=your_api_token_here
Claude Desktop / Claude Code
Add to your MCP config (claude_desktop_config.json or .mcp.json):
{
"mcpServers": {
"grok": {
"command": "uvx",
"args": ["mcp-grok"],
"env": {
"ACEDATACLOUD_API_TOKEN": "your_api_token_here"
}
}
}
}
Remote (HTTP)
A hosted Streamable HTTP endpoint is available at:
https://grok.mcp.acedata.cloud/mcp
Environment Variables
| Variable | Description | Default |
|---|---|---|
ACEDATACLOUD_API_TOKEN |
API token (required) | — |
ACEDATACLOUD_API_BASE_URL |
API base URL | https://api.acedata.cloud |
GROK_DEFAULT_MODEL |
Default model | grok-imagine-video-1.5-fast:reverse |
GROK_REQUEST_TIMEOUT |
Request timeout (seconds) | 180 |
MCP_SERVER_NAME |
MCP server name | grok |
MCP_TRANSPORT |
Transport mode (stdio/http) |
stdio |
LOG_LEVEL |
Logging level | INFO |
Usage Notes
- Generation is asynchronous: the generation tools return a
task_idquickly. Poll withgrok_get_task(task_id)until the state issucceededand thevideo_urlis available. - Generation typically takes ~30 seconds to a few minutes.
- Keep
resolutionat480panddurationshort for faster, cheaper iterations.
Development
pip install -e ".[dev,test]"
pytest --cov=core --cov=tools
ruff check .
Documentation
License
MIT — see LICENSE.
Install
Add mcp grok to your client. Pick the one you use.
{
"servers": {
"mcp-grok": {
"type": "http",
"url": "https://grok.mcp.acedata.cloud/mcp"
}
}
}Add to `.vscode/mcp.json` in your workspace.
claude mcp add mcp-grok -- uvx mcp-grokcodex mcp add mcp-grok -- uvx mcp-grokamp mcp add mcp-grok -- uvx mcp-grok{
"mcpServers": {
"mcp-grok": {
"command": "uvx",
"args": [
"mcp-grok"
]
}
}
}Add to `claude_desktop_config.json`, then restart Claude Desktop.
{
"mcpServers": {
"mcp-grok": {
"command": "uvx",
"args": [
"mcp-grok"
]
}
}
}Add to `~/.cursor/mcp.json`, or `.cursor/mcp.json` for a single project.
{
"mcpServers": {
"mcp-grok": {
"command": "uvx",
"args": [
"mcp-grok"
]
}
}
}Add to `~/.codeium/windsurf/mcp_config.json`.
{
"mcpServers": {
"mcp-grok": {
"command": "uvx",
"args": [
"mcp-grok"
]
}
}
}Add to `cline_mcp_settings.json` via the MCP Servers panel.
{
"mcpServers": {
"mcp-grok": {
"command": "uvx",
"args": [
"mcp-grok"
]
}
}
}Add to `~/.gemini/settings.json`.
{
"mcpServers": {
"mcp-grok": {
"type": "local",
"command": "uvx",
"args": [
"mcp-grok"
],
"tools": [
"*"
]
}
}
}Add to `~/.copilot/mcp-config.json`, or run `/mcp add` inside the CLI.
{
"context_servers": {
"mcp-grok": {
"command": {
"path": "uvx",
"args": [
"mcp-grok"
]
}
}
}
}Add to your Zed `settings.json`.
uvx mcp-grokRun `goose configure`, choose **Add Extension → Command-line Extension**, and paste this command.
8 tools
mcp grok exposes 8 tools to a connected agent.
- grok_chat_completions
- Chat completion (reasoning / vision / tool calling) with Grok chat models.
- grok_text_to_video
- Generate a video from a text prompt (any model except `grok-imagine-video-1.5:official`).
- grok_image_to_video
- Generate a video from an input image (+ optional motion prompt).
- grok_get_task
- Query the status/result of a single generation task.
- grok_get_tasks_batch
- Query the status/result of multiple tasks at once.
- grok_list_models
- List available models and their capabilities.
- grok_list_actions
- List all tools and example workflows.
- grok_get_prompt_guide
- Tips for writing effective video prompts.
Score
87 / 100
Excellent
- Documentation25/25
- Maintenance25/25
- Trust16/20
- Capability6/15
- Install experience15/15
- Documents what it does and how to connect
- Has a resolvable package or endpoint
- Exposes at least one tool, prompt or resource
- README has substantive content
- Includes a code example
- Documents its configuration
- Mentions credentials or security posture
- Last commit 4 days ago
- Has a release history
- Repository is not archived
- Licensed MIT
- Namespace verified in the official MCP registry
- Claimed by its owner
- Published under an organisation
- 8 tool(s) documented
- Provides prompt templates
- Provides resources
- 18 documented install method(s)
- Published to a package registry
- Offers a hosted endpoint — no local install
Version history
| Versions | Published |
|---|---|
| 2026.8.28.0Latest | Aug 28, 2026 |
| 2026.8.23.0 | Aug 23, 2026 |
| 2026.8.18.0 | Aug 18, 2026 |
| 2026.8.17.0 | Aug 17, 2026 |
| 2026.8.15.0 | Aug 15, 2026 |
| 2026.8.10.0 | Aug 10, 2026 |
| 2026.7.31.1 | Jul 31, 2026 |
| 2026.7.31.0 | Jul 31, 2026 |
| 2026.7.30.0 | Jul 30, 2026 |
| 2026.7.27.0 | Jul 27, 2026 |
| 2026.7.26.0 | Jul 26, 2026 |
| 2026.7.24.0 | Jul 24, 2026 |
| 2026.7.4.0 | Jul 4, 2026 |
| 2026.7.2.1 | Jul 2, 2026 |
| 2026.7.2.0 | Jul 2, 2026 |