{"id":49339723,"url":"https://github.com/citadel-cloud-management/mcp-server-database","last_synced_at":"2026-04-27T03:04:25.423Z","repository":{"id":345089257,"uuid":"1175451434","full_name":"Citadel-Cloud-Management/mcp-server-database","owner":"Citadel-Cloud-Management","description":"MCP server for database operations - PostgreSQL, MySQL, and SQLite queries and schema management","archived":false,"fork":false,"pushed_at":"2026-04-11T22:18:26.000Z","size":17,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-12T00:27:28.010Z","etag":null,"topics":["ai","anthropic","claude","database","llm","mcp","model-context-protocol","mysql","postgresql","sqlite","typescript"],"latest_commit_sha":null,"homepage":"https://citadel-cloud-management.github.io/mcp-server-database/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Citadel-Cloud-Management.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-07T18:21:31.000Z","updated_at":"2026-04-11T22:40:45.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/Citadel-Cloud-Management/mcp-server-database","commit_stats":null,"previous_names":["kogunlowo123/mcp-server-database"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/Citadel-Cloud-Management/mcp-server-database","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Citadel-Cloud-Management%2Fmcp-server-database","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Citadel-Cloud-Management%2Fmcp-server-database/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Citadel-Cloud-Management%2Fmcp-server-database/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Citadel-Cloud-Management%2Fmcp-server-database/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Citadel-Cloud-Management","download_url":"https://codeload.github.com/Citadel-Cloud-Management/mcp-server-database/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Citadel-Cloud-Management%2Fmcp-server-database/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32320688,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T23:26:28.701Z","status":"online","status_checked_at":"2026-04-27T02:00:06.769Z","response_time":128,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","anthropic","claude","database","llm","mcp","model-context-protocol","mysql","postgresql","sqlite","typescript"],"created_at":"2026-04-27T03:04:06.720Z","updated_at":"2026-04-27T03:04:25.418Z","avatar_url":"https://github.com/Citadel-Cloud-Management.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mcp-server-database\n\nAn MCP (Model Context Protocol) server that provides tools for interacting with relational databases. Supports PostgreSQL, MySQL, and SQLite.\n\n## Architecture\n\n```mermaid\ngraph TB\n    subgraph Client\n        style Client fill:#4A90D9,stroke:#2E6BA6,color:#FFFFFF\n        MCP_Client[\"MCP Client\"]\n    end\n\n    subgraph Server[\"mcp-server-database\"]\n        style Server fill:#2ECC71,stroke:#1A9B52,color:#FFFFFF\n        Index[\"index.ts\u003cbr/\u003eMCP Server Entry\"]\n        subgraph Tools\n            style Tools fill:#F39C12,stroke:#C67D0A,color:#FFFFFF\n            T1[\"query\"]\n            T2[\"list_tables\"]\n            T3[\"describe_table\"]\n            T4[\"list_databases\"]\n            T5[\"execute_migration\"]\n            T6[\"get_schema\"]\n        end\n    end\n\n    subgraph Databases[\"Database Engines\"]\n        style Databases fill:#9B59B6,stroke:#7D3C98,color:#FFFFFF\n        PG[\"PostgreSQL\"]\n        MY[\"MySQL\"]\n        SQ[\"SQLite\"]\n    end\n\n    MCP_Client -- \"stdio transport\" --\u003e Index\n    Index --\u003e T1 \u0026 T2 \u0026 T3 \u0026 T4 \u0026 T5 \u0026 T6\n    T1 --\u003e PG \u0026 MY \u0026 SQ\n    T2 --\u003e PG \u0026 MY \u0026 SQ\n    T3 --\u003e PG \u0026 MY \u0026 SQ\n    T4 --\u003e PG \u0026 MY\n    T5 --\u003e PG \u0026 MY \u0026 SQ\n    T6 --\u003e PG \u0026 MY \u0026 SQ\n```\n\n## Installation\n\n```bash\nnpm install\nnpm run build\n```\n\n## Configuration\n\n| Variable | Description | Required |\n|---|---|---|\n| `DB_DRIVER` | Database driver: `postgres`, `mysql`, or `sqlite` | Yes |\n| `DB_HOST` | Database host | Yes (postgres/mysql) |\n| `DB_PORT` | Database port | No |\n| `DB_USER` | Database username | Yes (postgres/mysql) |\n| `DB_PASSWORD` | Database password | Yes (postgres/mysql) |\n| `DB_NAME` | Database name | Yes |\n| `DB_PATH` | Path to SQLite file | Yes (sqlite) |\n\n## Usage\n\n### Standalone\n\n```bash\nDB_DRIVER=postgres DB_HOST=localhost DB_USER=admin DB_PASSWORD=secret DB_NAME=mydb npm start\n```\n\n### Development\n\n```bash\nnpm run dev\n```\n\n### Docker\n\n```bash\ndocker build -t mcp-server-database .\ndocker run -e DB_DRIVER=postgres -e DB_HOST=host.docker.internal -e DB_USER=admin -e DB_PASSWORD=secret -e DB_NAME=mydb mcp-server-database\n```\n\n### MCP Client Configuration\n\n```json\n{\n  \"mcpServers\": {\n    \"database\": {\n      \"command\": \"node\",\n      \"args\": [\"dist/index.js\"],\n      \"env\": {\n        \"DB_DRIVER\": \"postgres\",\n        \"DB_HOST\": \"localhost\",\n        \"DB_PORT\": \"5432\",\n        \"DB_USER\": \"admin\",\n        \"DB_PASSWORD\": \"secret\",\n        \"DB_NAME\": \"mydb\"\n      }\n    }\n  }\n}\n```\n\n## Tool Reference\n\n| Tool | Description | Parameters |\n|---|---|---|\n| `query` | Execute a SQL query | `sql`, `params?` |\n| `list_tables` | List all tables | none |\n| `describe_table` | Describe a table schema | `table_name` |\n| `list_databases` | List databases on the server | none |\n| `execute_migration` | Execute a migration SQL script | `sql` |\n| `get_schema` | Get full database schema DDL | none |\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcitadel-cloud-management%2Fmcp-server-database","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcitadel-cloud-management%2Fmcp-server-database","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcitadel-cloud-management%2Fmcp-server-database/lists"}