A lightweight, conversational TODO application demonstrating the Model Context Protocol (MCP) using fastmcp.
Control your tasks entirely via natural-language prompts in Claude Desktop, or via direct MCP JSON calls.
@mcp.tool()endpoints for create/update/delete@mcp.resource()endpoints for list/fetch
- Server-Sent Events (SSE) on
http://localhost:8000/mcp
- Clone this repo and
cdinto it:git clone https://github.com/hitenpratap/mcp-todo-python.git cd mcp-todo-python - Install dependencies via Pipenv and run the server:
pipenv install pipenv run python main.py
- In Claude Desktop, add an MCP server pointing either to your Python launcher or directly to the HTTP endpoint (see below).
- Use prompts like “Add a TODO: Buy groceries” or “Show me my open tasks”.
Add this to claude_desktop_config.json (update paths to match your setup):
When you select Todo Server in Claude Desktop’s hammer menu, it will spawn:
/ABSOLUTE/PATH/TO/YOUR/venv/bin/python /ABSOLUTE/PATH/TO/YOUR/project/todo-mcp/main.pyand automatically connect to http://localhost:8000/mcp.
If you prefer to run the MCP server yourself (e.g., pipenv run python main.py), use the url form:
{
"mcpServers": {
"Todo Server": {
"url": "http://localhost:8000/mcp"
}
}
}Claude will then send all MCP messages to that endpoint without launching a process.
{ "mcpServers": { "Todo Server": { "command": "/ABSOLUTE/PATH/TO/YOUR/venv/bin/python", "args": [ "/ABSOLUTE/PATH/TO/YOUR/project/todo-mcp/main.py" ] } } }