TodoSQLite MCP Server

TodoSQLite MCP Server

Enables users to manage a personal todo list with CRUD operations, keyword search, and local SQLite storage. Designed for AI agent productivity tools.

Category
访问服务器

README

TodoSQLite MCP Server 🗂️

Quản lý todo list cá nhân với lưu trữ SQLite local - hỗ trợ CRUD đầy đủ, search theo từ khóa, stateful và persistent. Lý tưởng cho AI agent productivity tool (giống Todoist mini hoặc Linear task manager).

Built with Node.js + TypeScript + FastMCP + better-sqlite3 + Zod — designed to demonstrate senior-level MCP tooling skills.


📦 Installation

# 1. Clone / navigate to project
cd /path/to/MyMCPServer

# 2. Install dependencies
npm install

# 3. (Optional) Build to JS
npm run build

Database: Automatically created at ~/.todo_mcp.db on first run. No setup needed.


🚀 Running the Server

Development (ts-node, recommended for local use)

npm run dev

Production (compiled JS)

npm run build && npm start

Type-check only

npm run typecheck

🛠️ Available Tools

Tool Description Key Params
add_todo Add a new task task (required), due_date (optional: "tomorrow", "today", "YYYY-MM-DD")
list_todos List all todos with [x]/[ ] status
toggle_todo Toggle completed/pending by ID id (integer)
delete_todo Permanently delete a task by ID id (integer)
search_todos Case-insensitive LIKE search keyword (string)

🗄️ Database Schema

CREATE TABLE todos (
  id          INTEGER PRIMARY KEY AUTOINCREMENT,
  task        TEXT    NOT NULL,
  completed   INTEGER NOT NULL DEFAULT 0,       -- 0=pending, 1=done
  created_at  TEXT    NOT NULL DEFAULT CURRENT_TIMESTAMP,
  due_date    TEXT                               -- ISO date e.g. "2026-03-01"
);

DB file location: ~/.todo_mcp.db (configurable via TODO_DB_PATH env var)


🔌 Connecting to Antigravity (Claude Desktop / MCP Client)

Add this entry to your mcp_config.json:

{
    "mcpServers": {
        "todo-sqlite": {
            "command": "npx",
            "args": [
                "ts-node",
                "--esm",
                "/absolute/path/to/MyMCPServer/src/index.ts"
            ],
            "env": {}
        }
    }
}

Or if using compiled JS:

{
    "mcpServers": {
        "todo-sqlite": {
            "command": "node",
            "args": ["/absolute/path/to/MyMCPServer/dist/index.js"],
            "env": {}
        }
    }
}

💬 Demo Prompts for Antigravity

# Add a task due tomorrow
@todo-sqlite Thêm task "Hoàn thành MCP server cho interview" due tomorrow

# List all todos
@todo-sqlite Liệt kê tất cả todos của tôi

# Search for a keyword
@todo-sqlite Tìm kiếm task liên quan đến "interview"

# Toggle task #1 as done
@todo-sqlite Đánh dấu task #1 là hoàn thành

# Delete task #3
@todo-sqlite Xóa task #3

# Workflow: add multiple, then list
Add these tasks:
- "Review PR #42" due today
- "Update README" due 2026-03-05
- "Write unit tests" due tomorrow
Then list all todos.

🏗️ Project Structure

MyMCPServer/
├── src/
│   ├── index.ts     # FastMCP server — 5 tools, Zod schemas, error handling
│   └── db.ts        # SQLite layer — prepared statements, typed CRUD functions
├── dist/            # Compiled output (after npm run build)
├── .env.example     # Environment variable reference
├── package.json
├── tsconfig.json
└── README.md

🧠 Architecture Highlights (for Interview Discussion)

Concern Approach
SQL Injection 100% prepared statements via better-sqlite3
Type safety Full TypeScript strict mode + Todo interface
Validation Zod schemas with .min(), .int(), .positive(), .describe()
Modularity DB logic isolated in src/db.ts, server in src/index.ts
Error handling Each tool wrapped in try/catch → friendly string messages
Persistence SQLite WAL mode, singleton DB connection
Natural language dates "tomorrow" / "today" resolved to ISO 8601 dates

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选