Give your content a structure of its own.

Start with a prompt or build visually. Define fields, relationships, and content structures with AI-assisted modelling that keeps you in control.

STAGE 01·AI Schema GeneratorPrompt Input
Authentic SCHMA AI Schema Generator workspace showing prompt brief input and generated schema structure
Proposal Handoff:Open in Schema Builder(Review & Refine before database commit)
STAGE 02·Schema BuilderModel: Article (article)
Configured Fields (5)Drag to reorder · Click to inspect
Titletitle
STRINGREQUIRED
URL Slugslug
STRINGREQUIRED
Body Contentbody
RICH TEXTLOCALIZED
Authorauthor
REFERENCE → AuthorREQUIRED
Cover Imagecover
IMAGEOPTIONAL
Field InspectorActive Selection
Author
author
reference
Target Reference Model

Author (author)

Connected via foreign reference. In queries, pass ?populate=author to expand the author object automatically.

Required value constraint
PostgreSQL JSONB schema definition · Instant zero-downtime evolution

Complete structural control
11 visual field types

From simple text and media to nested objects, repeatable lists, and content relationships. Configure your fields, define validation rules, and shape your schema before explicitly saving it.

Visual Field Types Catalog (11)Conceptual grouping for overview
Click to inspect
Primitives & Text
Relational & Media
Structural & Modular

Refine your structure in the builder. Your changes remain unsaved until you choose to save the schema.

All field definitions, identifier modifications, and validation rules are staged in memory. They commit to your PostgreSQL database only upon explicit schema save.

Article Title

string

Primitives & Text

Inspector Preview
Illustrative preview of field configuration options. Select a field type on the left to inspect its structure.
Article Title
Derived from label
title
Primary headline used for page display and browser tab titles.
Required
Non-empty check
Localizable
i18n per locale
String Validation Rules
Minimum Length
5 characters
Maximum Length
120 characters
Validation Pattern
^[A-Za-z0-9\s—:,.'"-]+$Illustrative configurable rule

Constraints are validated both client-side in the Studio editor and server-side on draft/publish transitions.

Verified Delivery API Relationship ResolutionHTTP GET
Request
GET /v1/delivery/entries?type=article&populate=author
Authorization: Bearer <DELIVERY_KEY>
Abbreviated Response Excerpt (1-level population)
{
  "entries": [
    {
      "dataJson": {
        "title": "A slower kind of Sunday",
        "author": {
          "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
          "dataJson": {
            "name": "Alex Morgan",
            "role": "Staff Writer"
          }
        }
      }
    }
  ]
}

Querying populate=author expands the foreign reference into the target published entry. Population is capped at 1 level depth; unresolved or unpublished references remain their original UUID strings.

Iterate in plain language
Inspect every change

Refine a schema with natural-language instructions. Review structured additions, updates, and removals against your previous proposal, then continue in the visual builder when you're ready.

Conference Event

slug: conference_eventUnsaved Proposal

Comparing Proposal v2 against Proposal v1 in client memory

1 Added1 Updated1 Removed
Refinement instruction appliedcomputeProposalDiff()

“Add a ticket_price number field, make title required, and remove venue_notes.”

Active Fields in Proposal (3)Click row to inspect diff
Removed from proposal:venue_notes(string)
-1 Removed

Omitted from active proposal table. If transferred to the Schema Builder, this field will not be created.

Successive prompts re-evaluate the proposal diff in client memory without writing to PostgreSQL.

Diff Inspectortitle
~ Updated
Field Typestring
Previous Proposal (v1)

required: false (optional)

Current Proposal (v2)

required: true (mandatory)

Validation Constraints

Required (entries must provide a value before saving draft or publishing)

Pure In-Memory Evaluation

Diffs are computed purely between memory models. No DDL operations, migrations, or database locks are created during conversational refinement.

Transient Client Memory vs. Explicit Persistence Boundary

AI clarification, schema proposal generation, and diff tracking happen entirely in client memory. No database tables, column mutations, or content types are altered until you explicitly review the fields in Schema Builder and click Save Schema.

POST /content-types

Every field rule compiles to an executable contract

SCHMA compiles saved content models into server-side Zod validators. Entry writes are checked against those rules before the validated content is persisted.

Runtime Validator Workbench

generateSchemaFromFields()

Illustrative request walkthrough based on verified server-side validation pipeline

Filter Field:
Content Model · Articleslug: article
titlestring
Required

Required string with 5 to 120 character bounds

published_datedate
Required

Accepted formats: YYYY-MM-DD, ISO 8601, or valid parseable date string

authorreference
Required

Required reference ID verified against target model

Explanatory Zod ExcerptCompiled via generateSchemaFromFields()
// Dynamic Zod object compiled at application layer
const ArticleSchema = z.object({
  title: z.string().min(5).max(120),
  published_date: z.string().refine((val) => /^\d{4}-\d{2}-\d{2}/.test(val) || !isNaN(Date.parse(val)), { message: "Invalid date format. Expected YYYY-MM-DD or valid date string." }),
  author: z.string() // Target entry verified via validateReferences(tx, ...),
}).passthrough();
Application-Layer Enforcement

Validation is evaluated in Node.js before database queries execute. It is distinct from PostgreSQL table-level column definitions or native CHECK constraints.

POST /entries
201 Created
Incoming Valid PayloadJSON request body
{
  "type": "article",
  "title": "A Considered Content Architecture",  "published_date": "2026-10-23",  "author": "usr_89f1a23c-0e4b-4f91",  "status": "draft"
}
Server Validation Pipeline: PassedReady for persistence
Payload conforms to ArticleSchema Zod contract
  • Zod parse: All string lengths, date formats, and required fields validated.
  • Sanitization: Rich text HTML tags sanitized via sanitizeRichText().
  • References: Target author entry verified in tenant database via validateReferences().
Status: Conforming content persistedstatus: "created"

Application-Level Reference Verification

Reference checks use validateReferences(tx, ...) to verify that referenced target IDs exist in the current tenant database. They are enforced at the API layer rather than through physical PostgreSQL foreign keys.

Contractual Data Integrity in Decoupled JSONB Storage

SCHMA stores entry payloads in unified JSONB columns while enforcing typed structural rigor via compiled Zod contracts. You get the flexibility of schema updates without PostgreSQL table-altering DDL migrations paired with strict validation guarantees before entries persist.

EntryService.create()

Evolve your schema
Keep existing content intact

Update your content model without automatically rewriting stored entries. SCHMA keeps schema definitions separate from entry data, so new fields can be introduced while existing draft and published payloads remain unchanged until you update them.

Schema metadata
schma_content_types.schema_json
V1Before
2 fields defined
title
stringrequired
author
referenceoptional
V2Updated
3 fields defined
title
stringrequired
author
referenceoptional
summary
stringNew field

Schema changes don't automatically migrate existing entries.

New validation rules apply when content is subsequently written or updated. Existing entries may need to be updated to satisfy newly introduced required fields or other changed constraints.

Existing entry data
schma_entries
Draft
data_json
title"Autumn Notes"
author"usr_42"
summaryNot present yet
Published
published_data_json
title"Autumn Notes"
author"usr_42"
summaryNot present yet
Illustrative representation of content-model decoupling. Existing stored records remain intact without DDL table migrations.
FROM SCHEMA TO WORKFLOW

Define the structure. Put it to work.

Create structured content, give your team a place to work with it, and deliver it to your applications through SCHMA's APIs.

SCHMA Instant Studio workspace and content editing interface

Instant Studio

Give your team a workspace for creating and editing structured content, with forms shaped by your content models.

SCHMA Delivery APIs query and JSON payload delivery

Delivery APIs

Query and deliver your structured content through SCHMA's REST and GraphQL APIs.

SCHMA Developer Workflow SDK and programmatic tooling

Developer Workflow

Explore the tools and integrations that connect SCHMA to your development workflow.

Questions about your content models?

Clear answers about schema creation, validation, database ownership, and evolving your content structure.