Ollama MCP Server
by rawveg
{
"name": "ollama-mcp",
"version": "1.0.2",
"type": "tool",
"tools": [
{
"name": "list_ollama_models",
"description": "List all available Ollama models",
"route": {
"path": "/models",
"method": "GET"
},
"parameters": {
"type": "object",
"properties": {}
}
},
{
"name": "pull_ollama_model",
"description": "Pull a new Ollama model",
"route": {
"path": "/models/pull",
"method": "POST"
},
"parameters": {
"type": "object",
"required": ["name"],
"properties": {
"name": {
"type": "string",
"description": "Name of the model to pull"
}
}
}
},
{
"name": "chat_with_ollama",
"description": "Chat with an Ollama model",
"route": {
"path": "/chat",
"method": "POST"
},
"parameters": {
"type": "object",
"required": ["model", "messages"],
"properties": {
"model": {
"type": "string",
"description": "Name of the model to chat with"
},
"messages": {
"type": "array",
"description": "Array of chat messages",
"items": {
"type": "object",
"required": ["role", "content"],
"properties": {
"role": {
"type": "string",
"enum": ["system", "user", "assistant"],
"description": "Role of the message sender"
},
"content": {
"type": "string",
"description": "Content of the message"
}
}
}
}
}
}
},
{
"name": "get_ollama_model_info",
"description": "Get information about a specific Ollama model",
"route": {
"path": "/models/:name",
"method": "GET"
},
"parameters": {
"type": "object",
"required": ["name"],
"properties": {
"name": {
"type": "string",
"description": "Name of the model to get information about"
}
}
}
}
],
"env": {
"PORT": {
"type": "number",
"default": 3456,
"description": "Port to run the server on"
},
"OLLAMA_API": {
"type": "string",
"default": "http://localhost:11434",
"description": "Ollama API endpoint"
}
}
}