schema
Export the JSON Schema for a semantic type — validation rules, examples, and DuckDB cast expressions.
Export the JSON Schema for any FineType type. Each schema includes a regex pattern, length constraints, examples, and the DuckDB expression needed to cast matching values.
Usage
finetype schema [OPTIONS] <TYPE_KEY>Arguments
| Argument | Description |
|---|---|
TYPE_KEY | Type key (e.g., identity.person.email) or glob pattern (e.g., identity.person.*) |
Options
| Flag | Type | Default | Description |
|---|---|---|---|
-f, --file | path | labels | Taxonomy file or directory |
--pretty | flag | — | Pretty-print JSON output |
Examples
Export a single type schema
$ finetype schema identity.person.email --pretty{
"$id": "https://meridian.online/schemas/identity.person.email",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Email Address",
"description": "Standard email address (RFC 5322 simplified)...",
"type": "string",
"pattern": "^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9]...",
"minLength": 5,
"maxLength": 254,
"examples": ["[email protected]", "[email protected]"],
"x-finetype-broad-type": "VARCHAR",
"x-finetype-pii": true,
"x-finetype-transform": "LOWER(CAST({col} AS VARCHAR))"
}Export all types in a category
Use a glob pattern to export every type within a category:
$ finetype schema "identity.person.*" --prettyThis outputs a JSON array of schemas for all types under identity.person — email, full name, username, and others.
Pipe to jq for specific fields
$ finetype schema identity.person.email | jq '.pattern'Schema fields
Every exported schema follows JSON Schema 2020-12 and includes FineType extensions:
| Field | Description |
|---|---|
$id | Permanent URL on meridian.online |
title | Human-readable type name |
description | What the type represents |
pattern | Regex that matching values conform to |
examples | Sample values for testing |
x-finetype-broad-type | DuckDB target type (VARCHAR, BIGINT, TIMESTAMP, etc.) |
x-finetype-pii | Whether the type may contain personally identifiable information |
x-finetype-transform | DuckDB SQL expression for safe casting ({col} is the column placeholder) |
See also
validate— validate data against these schemastaxonomy— browse the full type hierarchy- Type Registry — browse all types with schemas on the web