Provides chat, completions, embeddings, and model management endpoints for Grok AI via a fast MCP server.
Configuration
View docs{
"mcpServers": {
"brewmytech-grok-mcp": {
"url": "http://localhost:8080/stream",
"headers": {
"GROK_API_KEY": "YOUR_GROK_API_KEY"
}
}
}
}Grok MCP Server enables chat, completions, embeddings, and model operations with Grok AI through a fast, modular MCP setup. It exposes a streaming HTTP endpoint by default and supports multiple operation types with clear error handling and real-time responses.
You connect your MCP client to Grok MCP Server to perform chat interactions, text or image-based chat inputs, embeddings, and model management tasks. Use the provided tools to list models, inspect a model, generate chat completions or text completions, and compute embeddings. You can enable streaming to receive partial results as they are generated and you can mix text and images in chat sessions for richer interactions.
Prerequisites you need before installing:
- Node.js installed (recommended LTS version)
- npm (comes with Node.js) or another package manager you use
- A Grok API key if you plan to access Grok services over the cloud
- Optional: a local environment for development and testingConfiguration enables you to connect to remote MCP endpoints and to pass your Grok API key for authenticated access. By default, the server exposes an HTTP streaming endpoint on port 8080. You can run the server locally and point MCP clients to http://localhost:8080/stream when you are ready to test.
List available Grok models and their details.
Retrieve information for a specific model by its ID.
Generate a chat-based completion with optional streaming and sampling controls.
Generate a text completion with optional streaming and sampling controls.
Create vector embeddings from input text using a specified model.