
Db Metadata Extractor Mcp
io.github.Optisol-BusinessPublished by GitHub account Optisol-Businessv0.1.6Updated Oct 24, 2026
Extract database metadata from PostgreSQL, Snowflake, SQL Server, BigQuery, and Oracle.
Overview
Local MCP server that lets an assistant extract schema metadata from PostgreSQL, Snowflake, SQL Server, BigQuery and Oracle into JSON files and query it.
- What you can do
- Extract full schema metadata (tables, columns, primary keys, indexes, constraints) from PostgreSQL, Snowflake, SQL Server, BigQuery or Oracle, optionally limited to a schema or table list, and save it as a local JSON file with summary statistics. Search and filter previously extracted metadata files by table or column name, with pagination for large schemas.
- When to use it
- Useful when you want an assistant to inventory or document a database schema, compare or browse table and column structures, or produce a local JSON snapshot of metadata without a cloud service.
- Requirements
- Runs locally as a Python package (Python 3.8+) or Docker image over stdio; per-database drivers such as psycopg2-binary, snowflake-connector-python, pyodbc/pymssql, google-cloud-bigquery or oracledb. Needs network access to the target database and a database user with SELECT, USAGE and CONNECT rights; BigQuery needs a base64-encoded service account key.
Installation
In SourceWeft
- Open Db Metadata Extractor Mcp in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
mcp-name: io.github.Optisol-Business/db-metadata-extractor-mcp
Database Metadata Extractor MCP Server
A Model Context Protocol (MCP) server that extracts and queries database schema metadata from PostgreSQL, Snowflake, SQL Server, BigQuery, and Oracle databases.
Features
- ✅ Multi-database support: PostgreSQL, Snowflake, SQL Server (MSSQL), BigQuery, Oracle
- ✅ Complete schema extraction: Tables, columns, primary keys, indexes, constraints
- ✅ Local JSON output: Saves metadata directly to local folder (no cloud required)
- ✅ Query interface: Search and filter metadata by table/column names
- ✅ Pagination support: Browse large schemas efficiently
- ✅ VS Code integration: Works with VS Code Agent Mode
- ✅ CLI customizable: Transport options (stdio, HTTP)
Installation
From PyPI
From Source
Quick Start
1. Start the MCP Server
The server starts in stdio mode by default and listens for MCP client connections.
2. Configure in Claude Desktop
Add to ~/.config/Claude/claude_desktop_config.json (macOS/Linux) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
Restart Claude Desktop.
3. Use in Claude
Tell Claude:
Extract metadata from my PostgreSQL database and save it to
/tmp/output
Claude will use the server's tools to extract and query your database schema.
Tools
extract_metadata
Extracts complete schema metadata from a database.
Parameters:
db_type(required):postgresql,snowflake,sqlserver,bigquery,oracleoutput_path(required): Local directory for JSON outputdatabase_name: Database/schema namehost: Database host (not needed for BigQuery/Snowflake)port: Database portusername: Database userpassword: Database passwordschema_name: Specific schema (optional)tables: Array of table names to extract (optional)account: Snowflake account IDwarehouse: Snowflake warehouserole_name: Snowflake roleproject_id: BigQuery project IDservice_account_key: BigQuery service account JSON (base64 encoded)
Returns:
- File path where metadata was saved
- Summary statistics (table count, column count, etc.)
query_metadata
Query previously extracted metadata.
Parameters:
filepath(required): Path to metadata JSON filetable_name: Filter by table name (substring match)field_name: Filter by column name (substring match)page: Page number (default: 1)page_size: Results per page (default: 20)
Returns:
- Paginated table results matching filters
Examples
PostgreSQL
Parameters Claude will use:
Snowflake
Parameters:
BigQuery
Parameters:
Advanced Usage
Custom Transport
Start with HTTP transport:
Environment Variables
Output Format
The extracted metadata is saved as a JSON file with structure:
Requirements
- Python 3.8+
- For PostgreSQL:
psycopg2-binary - For Snowflake:
snowflake-connector-python - For SQL Server:
pyodbc,pymssql - For BigQuery:
google-cloud-bigquery - For Oracle:
oracledb
Troubleshooting
Connection Errors
Problem: "Unable to connect to database"
Solution: Verify credentials and network access:
Permission Errors
Problem: "Access denied" or "insufficient permissions"
Solution: Ensure database user has:
SELECTon tablesUSAGEon schemasCONNECTon databases
Large Schema Timeouts
Problem: Extraction times out on large databases
Solution: Extract specific schema/tables:
License
MIT License - See LICENSE file
Contributing
Contributions welcome! Please:
- Fork the repository
- Create feature branch
- Submit pull request
Support
- GitHub Issues: https://github.com/Optisol-Business/db-metadata-extractor-mcp/issues
- Documentation: See MCP_REGISTRY_GUIDE.md
Links
Source: README.md at commit 34ce92c
Tools
0Version history
1- v0.1.6LatestSep 16, 2026
Score
40% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts
Declare a license in the repository or the registry entry.