MCP Connector

Connect Your Database to AI IDEs

SchemaFlow MCP Server gives AI-IDEs like Cursor and Windsurf real-time PostgreSQL and Supabase schema access for smarter code generation.

Works with postgresqlsupabase

91
Spark score
out of 100
Updated Jun 2025
Version 1.0.0
Models
universal

Add to Favorites

Why it matters

Integrate your PostgreSQL or Supabase database schemas directly into your AI IDE. Get real-time context for smarter code generation and database analysis.

Outcomes

What it gets done

01

Retrieve full database schema details (tables, columns, relationships, functions).

02

Analyze database performance and security.

03

Validate schema alignment with best practices.

04

Provide live database context to AI IDEs via secure SSE connections.

Install

Add it to your toolbox

Run in your project directory:

curl -fsSL https://spark.entire.vc/get/vb-schemaflow | bash

Capabilities

Tools your agent gets

get_schema

Retrieves complete database schema information including tables, columns, relationships, and functions.

analyze_database

Performs comprehensive database analysis including performance analysis and security assessment.

check_schema_alignment

Validates PostgreSQL or Supabase schema against best practices and identifies potential issues.

Overview

SchemaFlow MCP Server

Gives AI-IDEs like Cursor and Windsurf real-time access to PostgreSQL and Supabase schemas over MCP through three tools: get_schema, analyze_database, and check_schema_alignment. Only schema metadata is exposed, never actual row data. Use when an AI-IDE needs accurate, current schema context for code generation against PostgreSQL or Supabase; not suited to tasks needing access to actual table data, which this connector deliberately excludes.

What it does

SchemaFlow MCP Server gives an AI-IDE live access to PostgreSQL and Supabase database schemas through the Model Context Protocol, so tools like Cursor, Windsurf, and VS Code with Cline can generate code with real-time schema context instead of stale or hand-copied schema notes. It exposes three MCP tools. get_schema retrieves complete schema information - tables, columns, relationships, functions, triggers, enums, and indexes - and accepts an optional query_type parameter to filter for just tables, columns, relationships, functions, triggers, enums, indexes, or all. analyze_database runs a comprehensive database analysis covering performance insights, security assessment, and structural recommendations. check_schema_alignment validates the schema against best practices and flags potential issues with actionable recommendations, including things like naming-convention checks.

Under the hood, schema data is loaded and cached through the SchemaFlow dashboard first; the AI-IDE then connects over MCP using secure token authentication and queries that cached schema in real time. Because it queries a cache rather than the live database directly, actual row data is never accessed or stored - only schema metadata (tables, columns, relationships, and so on) flows through the MCP connection. Each user's MCP token is unique and revocable, connections are encrypted, and tokens are scoped so they can only access that user's own cached schema.

When to use - and when NOT to

Use this when working in an AI-IDE against a PostgreSQL or Supabase database and the assistant needs accurate, current schema awareness - for example asking "what tables do I have," "show me all relationships," or "check schema alignment" and getting answers grounded in the real schema rather than a guess. It is not a data-querying or data-analysis tool: it deliberately excludes actual row data from the MCP connection, so it is not the right fit for tasks that need to read or reason about table contents rather than structure.

Capabilities

Beyond the three MCP tools, the underlying SchemaFlow platform includes interactive schema visualization through diagrams, multi-format schema export (JSON, Markdown, SQL, and Mermaid), a schema browser for navigating tables and relationships, performance analysis for optimization opportunities, and native Supabase project integration with direct connection support.

How to install

Getting started requires visiting the SchemaFlow dashboard to connect a PostgreSQL or Supabase database, load and cache its schema, and generate an MCP token. The server is then added to the AI-IDE's MCP configuration as an SSE-type server pointed at the SchemaFlow API with that token, for example in Cursor via Settings -> Features -> MCP -> Add New MCP Server:

{
  "name": "schemaflow",
  "type": "sse",
  "url": "https://api.schemaflow.dev/mcp/?token=your-token-here"
}

Windsurf and VS Code with Cline use the same type: sse configuration shape nested under mcpServers in their respective MCP settings files.

Who it's for

Developers using AI-IDEs against PostgreSQL or Supabase who want their assistant to generate code, migrations, or queries with accurate awareness of the real schema - tables, relationships, functions, triggers, enums, and indexes - without granting the assistant access to actual data.

Source README

SchemaFlow MCP Server

Real-time PostgreSQL & Supabase schema access for AI-IDEs via Model Context Protocol (MCP)

SchemaFlow MCP Server provides your AI-IDE with live access to PostgreSQL and Supabase database schemas through the Model Context Protocol. Get real-time schema context for smarter code generation in tools like Cursor, Windsurf, and VS Code + Cline.

๐Ÿš€ Quick Start

Visit SchemaFlow โ†’

1. Get Your MCP Token

Visit SchemaFlow Dashboard to:

  • Connect your PostgreSQL or Supabase database
  • Load and cache your schema
  • Generate an MCP token

2. Configure Your AI-IDE

For Cursor IDE:
  1. Open Cursor Settings
  2. Go to Features โ†’ MCP
  3. Click "Add New MCP Server"
  4. Use this configuration:
{
  "name": "schemaflow",
  "type": "sse",
  "url": "https://api.schemaflow.dev/mcp/?token=your-token-here"
}
For Windsurf IDE:

Add to your MCP configuration:

{
  "mcpServers": {
    "schemaflow": {
      "type": "sse",
      "url": "https://api.schemaflow.dev/mcp/?token=your-token-here"
    }
  }
}
For VS Code + Cline:

Configure in Cline's MCP settings:

{
  "mcpServers": {
    "schemaflow": {
      "type": "sse", 
      "url": "https://api.schemaflow.dev/mcp/?token=your-token-here"
    }
  }
}

๐Ÿ› ๏ธ Available MCP Tools

get_schema

Retrieves complete database schema information including tables, columns, relationships, functions, triggers, enums, and indexes from PostgreSQL or Supabase databases.

Parameters:

  • query_type (optional): Filter specific information (tables, columns, relationships, functions, triggers, enums, indexes, all)

Example AI queries:

  • "Show me my database schema"
  • "What tables do I have?"
  • "Show me all relationships"
  • "List database functions"

analyze_database

Performs comprehensive database analysis including performance insights, security assessment, and structural recommendations for PostgreSQL and Supabase databases.

Example AI queries:

  • "Analyze my database performance"
  • "Check database security"
  • "Review database structure"
  • "Give me a database overview"

check_schema_alignment

Validates your PostgreSQL or Supabase schema against best practices and identifies potential issues with actionable recommendations.

Example AI queries:

  • "Check schema alignment"
  • "Validate my database"
  • "Any schema issues?"
  • "Check naming conventions"

๐Ÿ”ง How It Works

  1. Schema Caching: When you load your schema in SchemaFlow dashboard, it's automatically cached for MCP access
  2. Secure Connection: Your AI-IDE connects using MCP with secure token authentication
  3. Real-time Access: Your AI assistant can query schema data in real-time for better code generation

๐Ÿ”’ Security

  • Schema metadata only - No actual data is accessed or stored
  • Token-based authentication - Each user has a unique, revokable token
  • Encrypted connections - All MCP communication is encrypted
  • User-specific access - Tokens only access your own cached schema data

๐Ÿ“š Complete Documentation

For detailed setup instructions, troubleshooting, and advanced configuration, visit:

Complete MCP Integration Guide

๐ŸŒ SchemaFlow Platform

This MCP server is part of the larger SchemaFlow platform which also provides:

  • Interactive Schema Visualization - Explore your PostgreSQL/Supabase database structure through intuitive diagrams
  • Multi-Format Export - Export schemas in JSON, Markdown, SQL, and Mermaid formats
  • Schema Browser - Navigate through tables, relationships, and database components
  • Performance Analysis - Get insights into your database structure and optimization opportunities
  • Supabase Integration - Native support for Supabase projects with direct connection

Visit SchemaFlow โ†’

๐Ÿ†˜ Support

๐Ÿ“„ License

MIT License - see LICENSE file for details.

FAQ

Common questions

Discussion

Questions & comments ยท 0

Sign In Sign in to leave a comment.