Document Schema
Properties
type (optional)
- Type:
string - Value:
document - Default:
document - Description: Identifies this configuration as a document. While optional due to the default value, including it explicitly helps with YAML validation and clarity.
type: documentdescription (optional)
- Type:
string - Description: A detailed explanation of the document’s purpose, content structure, or use case. Useful for documentation and team collaboration.
description: "Contains the complete order details including items, pricing, and shipping information"content (optional)
- Type:
any - Description: The actual data content of the document. Can be any valid YAML data structure including strings, numbers, objects, arrays, or template expressions.
content:
orderId: "ORD-12345"
items:
- name: "Widget A"
quantity: 2
price: 29.99
total: 59.98content: ${{ myData }}ui (optional)
- Type: UI Schema object
- Description: Defines how the document should be rendered in the Loopstack Studio interface. Contains two sub-properties:
formfor field rendering configuration, andactionsfor interactive buttons.
ui.form (optional)
Controls the visual presentation of document fields. Supports the following properties on the form level and on each field:
order- Array of field names controlling display orderproperties- A map of field names to their UI configuration
ui:
form:
order:
- name
- description
properties:
name:
title: Name
widget: text
description:
title: Description
widget: textareaui.actions (optional)
Defines interactive buttons that trigger workflow transitions. Each action is a discriminated union with a type field.
Button action (type: button):
| Property | Type | Description |
|---|---|---|
type | "button" | Action type identifier |
transition | string | The workflow transition ID to trigger |
widget | string (optional) | Widget type for rendering |
enabledWhen | string[] (optional) | List of places where this button is enabled |
options.label | string (optional) | Button label text |
options.position | number (optional) | Button position order |
options.props | object (optional) | Additional rendering properties |
Custom action (type: custom):
| Property | Type | Description |
|---|---|---|
type | "custom" | Action type identifier |
transition | string | The workflow transition ID to trigger |
widget | string (optional) | Widget type for rendering |
enabledWhen | string[] (optional) | List of places where this action is enabled |
options.label | string (optional) | Action label text |
options.props | object (optional) | Additional rendering properties |
ui:
actions:
- type: button
widget: button
transition: submit
options:
label: 'Submit'tags (optional)
- Type:
arrayof strings or template expression - Description: Labels to categorize and organize documents. Tags can be static strings or dynamic template expressions that evaluate at runtime. Useful for filtering, searching, and grouping related documents.
tags:
- customer-data
- processed
- high-prioritytags: ${{ args.categories }}Meta Properties
meta.hidden (optional)
- Type:
booleanor template expression - Description: Controls whether the document is visible in the Loopstack Studio interface. When set to
true, the document will be hidden from the UI but still accessible programmatically.
meta:
hidden: falsemeta:
hidden: ${{ config.hideInternalDocs }}meta.mimeType (optional)
- Type:
stringor template expression - Description: Specifies the MIME type of the document content, which affects how the content is interpreted and displayed.
Supported MIME types:
text/plain- Plain text contenttext/html- HTML formatted contenttext/css- CSS stylesheetstext/xml- XML documentstext/markdown- Markdown formatted textapplication/javascript- JavaScript codeapplication/typescript- TypeScript codeapplication/json- JSON structured dataapplication/xml- XML structured dataapplication/yaml- YAML structured data
meta:
mimeType: application/jsonmeta.invalidate (optional)
- Type:
booleanor template expression - Description: When omitted or set to
true, the document will be invalidated when the same document is created again in the same workflow. Invalidated documents still exist but will not be shown in the user interface. By default, invalidation is set to true.
meta:
invalidate: falsemeta.enableAtPlaces (optional)
- Type:
arrayof strings - Description: Specifies a whitelist of places or contexts where this document should be enabled. Only enabled documents can be edited via the interface. Documents are enabled by default at the state/place where they were created.
meta:
enableAtPlaces:
- dashboard
- admin-panel
- reportsmeta.hideAtPlaces (optional)
- Type:
arrayof strings - Description: Specifies a blacklist of places or contexts where this document should be hidden.
meta:
hideAtPlaces:
- public-view
- guest-dashboardmeta.data (optional)
- Type:
any - Description: Arbitrary metadata that can be attached to the document. Can hold any data structure for custom use cases.
meta:
data:
source: import
version: 2UI Form Element Properties
Each field in ui.form.properties supports the following configuration options:
| Property | Type | Description |
|---|---|---|
widget | string | The input widget type (e.g., text, textarea, select) |
title | string | Display label for the field |
label | string | Alternative display label |
placeholder | string | Placeholder text for input fields |
help | string | Help text displayed below the field |
descriptions | string | Additional descriptive text |
rows | number | Number of visible rows (for textarea widgets) |
index | number | Ordering index for the field |
inline | boolean | Render the field inline |
inputType | string | HTML input type (e.g., email, number) |
emptyValue | any | Default value when the field is empty |
titleFormat | string | Format string for the field title |
hidden | boolean | Hide the field from the form |
disabled | boolean | Disable the field (non-interactive) |
readonly | boolean | Make the field read-only |
collapsed | boolean | Collapse array/object fields by default |
order | string[] | Display order of nested fields |
enumOptions | array or string | Options for select/radio widgets (array of { label, value } objects or strings) |
addable | boolean | Allow adding items (for array fields) |
removable | boolean | Allow removing items (for array fields) |
movable | boolean | Allow reordering items (for array fields) |
accept | string | Accepted file types (for file upload widgets) |
multiple | boolean | Allow multiple selections or file uploads |
items | object | UI configuration for items in array fields |
properties | object | UI configuration for nested object fields |
Last updated on