MCP.so
登录

Sqlite Reader MCP Server

@abhinavnatarajan

基本信息

分类

数据库

许可证

MIT license

传输方式

stdio

作者

abhinavnatarajan

关于 Sqlite Reader MCP Server

MCP server for reading SQLite databases

Sqlite Reader MCP Server 配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "sqlite-reader-mcp": {
      "command": "uv",
      "args": [
        "tool",
        "install",
        "git+https://github.com/abhinavnatarajan/sqlite-reader-mcp"
      ]
    }
  }
}

Sqlite Reader MCP Server 工具

工具列表暂未提供

当前收录暂时没有可展示的工具列表,不代表服务没有工具。请查阅项目文档了解支持的能力。

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is sqlite-reader-mcp?

sqlite-reader-mcp is a lightweight MCP server that provides read-only access to SQLite databases. It allows users to execute SELECT queries, list tables, and describe table schemas. Aimed at developers and AI agents who need safe, programmatic exploration of SQLite databases through the Model Context Protocol.

How to use sqlite-reader-mcp?

Install with uv tool install git+https://github.com/abhinavnatarajan/sqlite-reader-mcp. Then start the server using sqlite-reader-mcp --paths /path/to/database.db /path/to/allowed_directory. Once running, interact via any FastMCP client using the built-in tools: read_query, list_tables, and describe_table.

Key features of sqlite-reader-mcp

  • Read-only access – no data modification allowed
  • Secure path whitelisting for approved database files
  • SQL validation permits only SELECT and WITH statements
  • Asynchronous operations with aiosqlite
  • Automatic row limiting (default 1000 rows)
  • Three MCP tools: read_query, list_tables, describe_table

Use cases of sqlite-reader-mcp

  • Safely explore SQLite databases through an MCP interface
  • Audit database schema and table structures
  • Run read-only analytical queries from an AI agent
  • Integrate SQLite data retrieval into LLM-driven workflows
  • Provide controlled database access without write risk

常见问题

1

What tools does sqlite-reader-mcp provide?

It provides three tools: `read_query` to execute SELECT queries, `list_tables` to list all tables in a database, and `describe_table` to get column schema information for a specific table.

2

How does the server enforce read-only security?

The server enforces read-only by rejecting any SQL that is not a SELECT or WITH statement. It also restricts database access to absolute file paths explicitly passed via the `--paths` argument, and validates that paths exist.

3

What are the runtime requirements?

Python 3.13 or later, plus the packages `aiosqlite >= 0.21.0`, `fastmcp >= 2.6.1`, and `sqlparse >= 0.5.3`.

4

How do I specify which databases the server can access?

Use the `--paths` (or `-p`) command-line argument with one or more absolute paths to SQLite database files or directories containing them. All paths must exist and be absolute.

5

Can I execute multiple SQL statements in one query?

No. The server rejects query strings containing multiple statements to prevent injection or unintended operations. Trailing semicolons are automatically removed.

评论

数据库 分类下的更多 MCP 服务器