text2sql
io.github.cpenniman12/text2sql-mcp
Ask any SQL database in natural language. Agent explores schema, writes SQL, self-corrects.
- Repository
- github.com/cpenniman12/text2sql-mcp
- Version
- 0.1.2
- Author
- cpenniman12 (namespace verified by the registry)
- Source
- Official MCP registry (updated Jun 28, 2026)
How to install it
Variables to fill in: TEXT2SQL_DATABASE_URL, ANTHROPIC_API_KEY, OPENAI_API_KEY, TEXT2SQL_MODEL.
On your machine
Claude Code
The server runs on your machine (pypi package). In a terminal:
claude mcp add text2sql-mcp -e TEXT2SQL_DATABASE_URL=YOUR_TEXT2SQL_DATABASE_URL -e ANTHROPIC_API_KEY=YOUR_ANTHROPIC_API_KEY -e OPENAI_API_KEY=YOUR_OPENAI_API_KEY -e TEXT2SQL_MODEL=YOUR_TEXT2SQL_MODEL -- uvx [email protected]Claude Desktop claude_desktop_config.json
Settings, Developer, Edit config, then add:
{
"mcpServers": {
"text2sql-mcp": {
"command": "uvx",
"args": [
"[email protected]"
],
"env": {
"TEXT2SQL_DATABASE_URL": "YOUR_TEXT2SQL_DATABASE_URL",
"ANTHROPIC_API_KEY": "YOUR_ANTHROPIC_API_KEY",
"OPENAI_API_KEY": "YOUR_OPENAI_API_KEY",
"TEXT2SQL_MODEL": "YOUR_TEXT2SQL_MODEL"
}
}
}
}Cursor ~/.cursor/mcp.json
In ~/.cursor/mcp.json:
{
"mcpServers": {
"text2sql-mcp": {
"command": "uvx",
"args": [
"[email protected]"
],
"env": {
"TEXT2SQL_DATABASE_URL": "YOUR_TEXT2SQL_DATABASE_URL",
"ANTHROPIC_API_KEY": "YOUR_ANTHROPIC_API_KEY",
"OPENAI_API_KEY": "YOUR_OPENAI_API_KEY",
"TEXT2SQL_MODEL": "YOUR_TEXT2SQL_MODEL"
}
}
}
}VS Code .vscode/mcp.json
In .vscode/mcp.json:
{
"servers": {
"text2sql-mcp": {
"type": "stdio",
"command": "uvx",
"args": [
"[email protected]"
],
"env": {
"TEXT2SQL_DATABASE_URL": "YOUR_TEXT2SQL_DATABASE_URL",
"ANTHROPIC_API_KEY": "YOUR_ANTHROPIC_API_KEY",
"OPENAI_API_KEY": "YOUR_OPENAI_API_KEY",
"TEXT2SQL_MODEL": "YOUR_TEXT2SQL_MODEL"
}
}
}
}ChatGPT
ChatGPT only connects to remote servers (an https address). This package runs locally: use one of the apps above.
These configurations are built from the information published by the author. Check the repository before installing a local server.
Our test
This server runs on your machine: we cannot test it remotely.
Reviews
No review yet.
Sign in to leave a review. Your email is all you need.
Comments
No comment yet. A question, a tip? Start the discussion.
Sign in to comment.
Badge for your README
Show that your project is listed (and tested, if it responds): paste this code in your README. The badge follows the latest test and links back to this entry.
Markdown (GitHub)
[](https://lagora.dev/en/entry/io.github.cpenniman12/text2sql-mcp)HTML
<a href="https://lagora.dev/en/entry/io.github.cpenniman12/text2sql-mcp"><img src="https://lagora.dev/badge/io.github.cpenniman12/text2sql-mcp.svg?lang=en" alt="io.github.cpenniman12/text2sql-mcp on L’Agora" height="20"></a>For the entry’s author only: sign in to continue.