Skip to main content
Programming Language

The Orbital Language

Almadar is a declarative schema language for full-stack applications. Define entities, state machines, and UI in a single .orb file — the compiler generates the rest.

How It Works

Every Almadar application is composed of Orbital Units. An Entity holds your data, Traits define behavior as state machines, and Pages bind them to routes. Watch the architecture assemble itself.

APP: ORDER FULFILLMENT APPOrder(Entity)Fulfillment(Trait)Track Order(Page)placedprepshippeddoneverifydispatcharriveOrbital Unit = Entity + Traits + Pages

Orbital Unit = Entity + Traits + Pages

Core Concepts

Three building blocks compose every Almadar application

EntityData shape

Entities define your data model. Fields are typed, can have defaults, and support three persistence modes: runtime (in-memory), persistent (database), and singleton.

{
  "name": "Task",
  "persistence": "runtime",
  "fields": [
    { "name": "title", "type": "string" },
    { "name": "done",  "type": "boolean", "default": false }
  ]
}
TraitState machine + UI

Traits model behavior as state machines with states, events, guards, and effects. Effects can set entity fields, emit events, call services, or render UI patterns.

PageRoute binding

Pages bind Orbitals to routes. They define the URL, the layout, and which Orbitals (groups of Entity + Traits) are mounted. Pages are generated as React route components.

First Schema in 60 Seconds

Install the CLI, create your first schema, and compile it to a running application.

npx @almadar/cli new my-app
1Install the CLI
2Edit your .orb schema
3Run almadar dev my-app.orb to watch and compile
Full Getting Started Guide
hello-world.orb
{
  "name": "HelloWorld",
  "orbitals": [{
    "name": "Greeter",
    "entity": {
      "name": "Greeting",
      "fields": [
        { "name": "message", "type": "string" },
        { "name": "count", "type": "number", "default": 0 }
      ]
    },
    "traits": [{
      "name": "Clickable",
      "stateMachine": {
        "states": [
          { "name": "idle", "isInitial": true },
          { "name": "greeted" }
        ],
        "transitions": [{
          "from": "idle",
          "event": "CLICK",
          "to": "greeted",
          "effects": [
            ["set", "@entity.message", "Hello, World!"],
            ["set", "@entity.count", ["+", "@entity.count", 1]],
            ["render-ui", "main", {
              "type": "stats-card",
              "title": "@entity.message",
              "value": "@entity.count"
            }]
          ]
        }]
      }
    }]
  }]
}

Live Component Preview

render-ui turns an s-expression into a real component — no JSX, no template files. Edit the expression and watch the preview update automatically.

Try It in the Browser

Run Almadar s-expressions live — no installation needed

Loading playground...