Any Chat Completions
Integrate Claude with Any OpenAI SDK Compatible Chat Completion API - OpenAI, Perplexity, Groq, xAI, PyroPrompts and more.
What is Any Chat Completions?
Any Chat Completions is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to integrate claude with any openai sdk compatible chat completion api - openai, perplexity, groq, xai, pyroprompts and more.
Integrate Claude with Any OpenAI SDK Compatible Chat Completion API - OpenAI, Perplexity, Groq, xAI, PyroPrompts and more.
This server falls under the Coding Agents category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Integrate Claude with Any OpenAI SDK Compatible Chat Complet
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx any-chat-completionsConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Any Chat Completions
any-chat-completions-mcp lets Claude Desktop and other MCP clients talk directly to any OpenAI SDK-compatible chat completion API — including OpenAI, Perplexity, Groq, xAI, and PyroPrompts — by exposing a single `chat` tool per configured provider. You can run multiple provider instances side-by-side in one config file, enabling Claude to delegate questions to Perplexity for live web search results, Groq for fast inference, or any other compatible endpoint without leaving your conversation.
Prerequisites
- Node.js 18+ and npm installed
- Claude Desktop or another MCP-compatible client
- API key(s) for the providers you want to use (OpenAI, Perplexity, Groq, xAI, etc.)
- The base URL of any OpenAI-compatible endpoint you plan to configure
Install via Smithery (recommended)
The fastest way to install is via the Smithery CLI, which handles package installation and config wiring automatically.
npx -y @smithery/cli install any-chat-completions-mcp-server --client claudeOr clone and build manually
Alternatively, clone the repository, install dependencies, and compile the TypeScript source.
git clone https://github.com/pyroprompts/any-chat-completions-mcp.git
cd any-chat-completions-mcp
npm install
npm run buildOpen Claude Desktop config
Open your Claude Desktop configuration file in a text editor. It lives at `~/Library/Application Support/Claude/claude_desktop_config.json` on macOS or `%APPDATA%\Claude\claude_desktop_config.json` on Windows.
Add one or more provider entries
Each provider gets its own named entry under `mcpServers`. Set the four environment variables — AI_CHAT_KEY, AI_CHAT_NAME, AI_CHAT_MODEL, and AI_CHAT_BASE_URL — for each provider you want to use.
{
"mcpServers": {
"perplexity": {
"command": "npx",
"args": ["@pyroprompts/any-chat-completions-mcp"],
"env": {
"AI_CHAT_KEY": "pplx-your-api-key",
"AI_CHAT_NAME": "Perplexity",
"AI_CHAT_MODEL": "sonar",
"AI_CHAT_BASE_URL": "https://api.perplexity.ai"
}
},
"groq": {
"command": "npx",
"args": ["@pyroprompts/any-chat-completions-mcp"],
"env": {
"AI_CHAT_KEY": "gsk_your-groq-key",
"AI_CHAT_NAME": "Groq",
"AI_CHAT_MODEL": "llama-3.3-70b-versatile",
"AI_CHAT_BASE_URL": "https://api.groq.com/openai"
}
}
}
}Restart Claude Desktop
Fully quit and reopen Claude Desktop (not just close the window) so it picks up the new MCP server entries. You should see the provider names appear in the tools list.
Any Chat Completions Examples
Client configuration
Full example showing OpenAI and xAI configured side by side in claude_desktop_config.json.
{
"mcpServers": {
"openai": {
"command": "npx",
"args": ["@pyroprompts/any-chat-completions-mcp"],
"env": {
"AI_CHAT_KEY": "sk-your-openai-key",
"AI_CHAT_NAME": "OpenAI",
"AI_CHAT_MODEL": "gpt-4o",
"AI_CHAT_BASE_URL": "https://api.openai.com"
}
},
"xai": {
"command": "npx",
"args": ["@pyroprompts/any-chat-completions-mcp"],
"env": {
"AI_CHAT_KEY": "xai-your-key",
"AI_CHAT_NAME": "xAI",
"AI_CHAT_MODEL": "grok-2",
"AI_CHAT_BASE_URL": "https://api.x.ai"
}
}
}
}Prompts to try
Once configured, you can explicitly route questions to each provider using its name in your prompt.
- "Ask Perplexity: what are the latest developments in fusion energy this week?"
- "Use Groq to summarize this text as fast as possible: [paste text]"
- "Ask OpenAI gpt-4o to review this code for security vulnerabilities: [paste code]"
- "Compare answers from Perplexity and OpenAI on the best Python web frameworks in 2025."Troubleshooting Any Chat Completions
The `chat` tool does not appear in Claude Desktop after adding the config
Make sure you fully quit Claude Desktop (Cmd+Q on macOS, not just close the window) and reopen it. Also verify there are no JSON syntax errors in claude_desktop_config.json by running it through a JSON validator.
Tool call returns '401 Unauthorized' or 'Invalid API key'
Check that AI_CHAT_KEY is set to your actual provider API key with no extra spaces or quotes. Confirm AI_CHAT_BASE_URL matches the provider's exact base URL (e.g., `https://api.perplexity.ai`, not `https://api.perplexity.ai/v1`).
Model not found error when the tool is called
Verify AI_CHAT_MODEL matches the exact model identifier used by the provider (e.g., `sonar` for Perplexity, `grok-2` for xAI). Check the provider's documentation for the current list of available model IDs.
Frequently Asked Questions about Any Chat Completions
What is Any Chat Completions?
Any Chat Completions is a Model Context Protocol (MCP) server that integrate claude with any openai sdk compatible chat completion api - openai, perplexity, groq, xai, pyroprompts and more. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Any Chat Completions?
Follow the installation instructions on the Any Chat Completions GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Any Chat Completions?
Any Chat Completions works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Any Chat Completions free to use?
Yes, Any Chat Completions is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.
Any Chat Completions Alternatives — Similar Coding Agents Servers
Looking for alternatives to Any Chat Completions? Here are other popular coding agents servers you can use with Claude, Cursor, and VS Code.
Dify
★ 142.2kProduction-ready platform for agentic workflow development.
Ruflo
★ 54.0k🌊 The leading agent orchestration platform for Claude. Deploy intelligent multi-agent swarms, coordinate autonomous workflows, and build conversational AI systems. Features enterprise-grade architecture, self-learning swarm intelligence, RAG integrat
Goose
★ 45.7kan open source, extensible AI agent that goes beyond code suggestions - install, execute, edit, and test with any LLM
Antigravity Awesome Skills
★ 38.3kInstallable GitHub library of 1,400+ agentic skills for Claude Code, Cursor, Codex CLI, Gemini CLI, Antigravity, and more. Includes installer CLI, bundles, workflows, and official/community skill collections.
AgentScope
★ 25.5kBuild and run agents you can see, understand and trust.
Serena
★ 24.5kA coding agent toolkit that provides IDE-like semantic code retrieval and editing tools, enabling LLMs to efficiently navigate and modify codebases using symbol-level operations instead of basic file reading and string replacements.
Browse More Coding Agents MCP Servers
Explore all coding agents servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Any Chat Completions in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Any Chat Completions?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.