Skip to Content

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: document

title (optional)

  • Type: string
  • Description: A human-readable name for your document. This helps identify and organize your documents in the Loopstack AI interface.
title: "Order Summary"

description (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 (required)

  • 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.98
content: ${ myData }

ui (optional)

  • Type: UI Schema object
  • Description: Defines how the document should be rendered in the Loopstack Studio interface. Controls the visual presentation and interaction patterns for document data.
ui: properties: myTextField: widget: 'textarea'

tags (optional)

  • Type: array of 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-priority
tags: ${ args.categories }

Meta Properties

meta.hidden (optional)

  • Type: boolean or 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: false
meta: hidden: ${ config.hideInternalDocs }

meta.mimeType (optional)

  • Type: string or 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 content
  • text/html - HTML formatted content
  • text/css - CSS stylesheets
  • text/xml - XML documents
  • text/markdown - Markdown formatted text
  • application/javascript - JavaScript code
  • application/typescript - TypeScript code
  • application/json - JSON structured data
  • application/xml - XML structured data
  • application/yaml - YAML structured data
meta: mimeType: application/json

meta.invalidate (optional)

  • Type: boolean or 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. Be default, invalidation is set to true.
meta: invalidate: false

meta.enableAtPlaces (optional)

  • Type: array of strings
  • Description: Specifies a whitelist of places or contexts where this document should be enabled. Only enabled documents can be edited via interface. Documents are enabled by default at the state/place where they were created.
meta: enableAtPlaces: - dashboard - admin-panel - reports

meta.hideAtPlaces (optional)

  • Type: array of strings
  • Description: Specifies a blacklist of places or contexts where this document should be hidden.
meta: hideAtPlaces: - public-view - guest-dashboard
Last updated on