0
Tables
0
Schemas
0
Columns
0
Enums
Tip: Include CHECK constraints with enum-like values (e.g., CHECK (status IN ('active', 'inactive'))) to auto-detect OpenAPI enums. Column COMMENT strings become schema descriptions.
# Select OpenAPI or JSON Schema, then paste SQL to generate

Need to compare two schemas?

SchemaLens diffs SQL schemas in your browser and generates migration scripts. Free for up to 15 tables.

Open SchemaLens Diff →

How It Works

1. Paste SQL

Paste any CREATE TABLE dump. Supports PostgreSQL, MySQL, SQLite, SQL Server, and Oracle syntax.

2. Smart Type Mapping

SQL types are automatically mapped to OpenAPI formats: INTEGERinteger, TIMESTAMPdate-time, UUIDuuid, JSONobject.

3. Export & Use

Copy the generated schema into your openapi.yaml, Swagger UI, or JSON Schema validator. Download as .yaml or .json.

Supported Schema Features

Copied to clipboard!