# Open App Definition > Open App Definition is an open format that describes a whole app as one JSON file. You ask an AI assistant for an app in plain words, the assistant writes the file, and a host runs it: in a browser, inside a chat, or as tools that an AI agent can call. The format is at version 0.2, a working draft that may change before 1.0. This site serves its specification, its JSON Schemas, the core catalog and the authoring guide. Everything on it is generated from the project's repository. The guide and the specification are in full, as one text, at https://openappdefinition.org/llms-full.txt: a model that reads it can write an app. ## Writing an app (the guide) - [Writing your first app](https://openappdefinition.org/guide/start.html): What an app is, the smallest complete app, a list you can add to and change, the fields of a record, the controls and list functions a first app uses, the examples to start from, how to work, and the mistakes every newcomer makes; enough for a first app. - [State](https://openappdefinition.org/guide/state.html): Stored, derived and sourced values, their types, where each value lives (scope) and who sees it. - [Expressions](https://openappdefinition.org/guide/expressions.html): The expression language: where the leading = goes, operators, functions, dates and times, list macros, and the habits from other languages that break here. - [Actions and steps](https://openappdefinition.org/guide/actions.html): Actions with input, allow, require and confirm, every step kind, handling failures, and doing an outside effect once. - [Views](https://openappdefinition.org/guide/views.html): The visual surface: views, nodes, props, bindings, handlers, view state, forms, navigation and main sections, and the card an app of one view is drawn as. - [Controls](https://openappdefinition.org/guide/controls.html): Every core control with its props, events and slots, generated from the core catalog, with advice on which to use. - [Capabilities and grants](https://openappdefinition.org/guide/capabilities.html): Using the outside world through a capability contract, asking for permission with a grant request, when each request is asked, and every core capability with its operations, generated from the core catalog. - [Sample data](https://openappdefinition.org/guide/sample-data.html): How a sample document answers for a service so an app runs without one, and how to write it. - [Mistakes and their fixes](https://openappdefinition.org/guide/mistakes.html): The mistakes nothing reports, then the diagnostics a writer meets most, each with its cause and its fix. - [Rules](https://openappdefinition.org/guide/rules.html): Reacting to changes, events, time and the app opening: triggers, edges and timers. - [Flows](https://openappdefinition.org/guide/flows.html): State machines for processes with named stages: singleton and collection flows, transitions, guards and timers. - [Code modules](https://openappdefinition.org/guide/code.html): Logic that expressions cannot say, or would have to say in several places, written once as a small sandboxed function: when to write one and when not, how an action calls it, and its limits and failures. - [People and roles](https://openappdefinition.org/guide/people.html): Several people on one app: shared state, ids and names, roles, only the owner may, who uses the app, and who may act. - [Agents](https://openappdefinition.org/guide/agents.html): What an app gives an agent: tools, resources, events and instructions, and how to keep what is private off the agent surface. - [Parts: apps inside apps](https://openappdefinition.org/guide/parts.html): Including a whole app inside another, for a piece several apps share or one that is useful alone and inside a larger app (most apps need none): exports, uses.definitions, parts, and how to work with both apps as drafts. - [Changing an app](https://openappdefinition.org/guide/changing.html): Editing an app in small steps with patches, the changes that need a person's yes, history, versions, and what happens to the data of people who use it. - [Texts in several languages](https://openappdefinition.org/guide/languages.html): An app's own texts in several languages: the localization table, keys, blanks and forms, t() in expressions and =t('key') in fixed places, adding a language or a key, right to left, looking as a reader of a language, and what each check of it means. - [Example apps](https://openappdefinition.org/guide/examples.html): the small apps the guide quotes, each a whole definition. ## Specification 0.2 - [Core Specification](https://openappdefinition.org/spec/0.2/core.html): An app definition is a single JSON document that describes what an app does: the values it holds, the things it can do, when it does them, what it needs from the outside world, what it is permitted to touch, and how people and agents use it. - [Catalogs and Contracts](https://openappdefinition.org/spec/0.2/contracts.html): A catalog is a versioned, publishable JSON document (*.oadcatalog.json) that holds contracts. - [Expressions](https://openappdefinition.org/spec/0.2/expressions.html): This chapter defines the expression language used throughout an app definition: in fields marked expression, in dynamic values (strings that start with =), and in paths (core.md, section "Values and expressions"). - [Validation](https://openappdefinition.org/spec/0.2/validation.html): This chapter lists the semantic checks that a definition, a catalog and a design system pass in addition to their JSON Schemas. - [Changes from 0.1](https://openappdefinition.org/spec/0.2/changes.html): This document lists what changed in OAD from draft 0.1 to draft 0.2, and why, for a reader who knows 0.1. ## JSON Schemas 0.2 - [OAD 0.2 catalog](https://openappdefinition.org/schema/0.2/catalog.schema.json): A catalog (*.oadcatalog.json): a versioned, publishable document that holds contracts. - [OAD 0.2 shared definitions](https://openappdefinition.org/schema/0.2/common.schema.json): Definitions shared by the Open App Definition 0.2 document schemas. - [OAD 0.2 app definition](https://openappdefinition.org/schema/0.2/definition.schema.json): An app definition (*.oad.json): a single JSON document that describes what an app does, the values it holds, the things it can do, when it does them, what it needs from the outside world, what it is permitted to touch, and how people and agents use it. - [OAD 0.2 design system](https://openappdefinition.org/schema/0.2/design.schema.json): A design system (*.oaddesign.json): a separately versioned document that supplies tokens, variants, custom control catalogs and agent conventions. - [OAD 0.2 history sidecar](https://openappdefinition.org/schema/0.2/history.schema.json): A history sidecar (*.oad.history.json): the ordered entries that record how a definition changed. - [OAD 0.2 signature sidecar](https://openappdefinition.org/schema/0.2/signature.schema.json): A signature sidecar beside a definition, catalog or design system, named after the document's file name with its final .json replaced by .sig.json (com.example.brand.oaddesign.json is signed by com.example.brand.oaddesign.sig.json): detached signatures over the document's digest. ## Reference - [Core catalog](https://openappdefinition.org/catalog/): every control and capability of the core catalog with its props, events, slots and operations. - [Docs](https://openappdefinition.org/docs/): the reference pages with a sentence on each, what exists today, where the project stands and the license. - [Four differences, and what shows them](https://openappdefinition.org/differences.html): how an app differs from a page an assistant draws in a chat, each shown by what the build made from the repository. - [Examples](https://openappdefinition.org/examples/): every example app of the repository, pictured, with its own description and a link that opens it in the playground (https://openappdefinition.org/playground/?example=). - [Get started](https://openappdefinition.org/start.html): three ways to have an assistant build an app, then writing, checking and running one yourself. - [Playground](https://openappdefinition.org/playground/): the example apps running in a browser page, with no server; https://openappdefinition.org/playground/?example=own checks and runs a definition pasted into it. - [Components](https://openappdefinition.org/components/): the built-in controls of the core catalog, running, with an index of every control. - [Build your own components](https://openappdefinition.org/components/build-your-own.html): how a vendor describes controls and capabilities in a catalog, what a host does with a control it cannot draw, and how a host adds a renderer. - [Repository](https://github.com/DataficationSDK/OpenAppDefinition): the specification, schemas, catalog, reference implementation and examples.