litellm-mcp
Allows interaction with local Ollama models through the LiteLLM gateway for single-turn and multi-turn queries.
Click on "Install 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., "@litellm-mcpexplain the concept of recursion"
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.
litellm-mcp
MCP server that lets Claude Code dispatch tasks to the LiteLLM gateway
(192.168.10.175:4000) as worker agents. Unlike ollama-mcp (which reaches only the
local Ollama models directly), this shim reaches the full gateway model set — the
local Ollama models and the Anthropic-via-gateway models
(claude-sonnet-4-6, claude-haiku-4-5).
Tools
list_models()— model ids registered on the gateway.ask_model(prompt, model=None, system=None)— single-turn worker call. Defaults toqwen2.5:7b-instruct(a reliable non-reasoning local model — a safer headless default than the reasoning modelqwen3.5:4b).chat(messages, model=None)— multi-turn.
Related MCP server: MCP-Demo
Credentials — per-request header (not at rest on Proteus)
This shim brokers spend on Anthropic, so the gateway master key is sensitive. It is not
stored in /etc/mcp/litellm-mcp.env on the shared Proteus host. Instead the key travels as a
per-request header from the client's ~/.claude.json:
"litellm": {
"type": "sse",
"url": "http://192.168.10.190:8107/sse",
"headers": { "x-litellm-key": "<LITELLM_MASTER_KEY from Infisical>" }
}The server reads x-litellm-key (or Authorization: Bearer ...) from each tool call. For
local/stdio use, LITELLM_API_KEY env is accepted as a fallback.
Config (non-sensitive, env file on Proteus)
Var | Default |
|
|
|
|
|
|
Tests
pip install -e ".[test]"
pytest -q # unit (respx-mocked)
LITELLM_API_KEY=... pytest -q # also runs live integration against the gatewayIntegration tests skip automatically when the gateway is unreachable or LITELLM_API_KEY
is unset (e.g. in CI on the GitLab runner). Deploy is via GitLab CI → Proteus
(/opt/mcp/litellm-mcp/, systemd litellm-mcp.service, port 8107).
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/LeonRLewis/litellm-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server