Skip to main content
DATA MODELING & CODE GENERATION

One data model. Every part of your stack.

Define the data your applications share. Generate types for Rust, TypeScript, and Python, plus JSON Schema for your wire format.

schemas/task.sidexsidex
//! Tasks shared by a service, a web app, and a Python tool.

/// A task to complete.
record Task {
    /// Short title shown in a task list.
    title: string,
    /// Whether the task is complete.
    completed: bool,
    /// Additional detail, when provided.
    description?: string,
}

A Shared Contract, Native Types

Records, variants, generics, and distinct wrapper types express your model. Attributes control its JSON representation and adapt it to each language.

From Your First Schema to a Shared API

Model Your Data

Make required fields, optional values, and alternative states explicit. Organize reusable types into bundles.

Learn the Language

Agree on the Wire Format

Choose field names and variant tags, then use the same JSON representation across your applications.

Understand JSON Mapping

Validate and Evolve

Share validation rules between Rust and TypeScript. Document introductions, experimental features, and deprecations.

Add Validation Rules

Try Sidex in Your Terminal

Run the CLI with npm or Python tooling. Prebuilt packages include the native executable for Linux and macOS on x64 and ARM64.

npx sidex-cli --help
uvx sidex-cli --help

Sidex is under active development. These docs describe the main branch. Use a matching CLI version when following examples. Installation Options