ObjectStackObjectStack

Settings Manifest

Settings Manifest protocol schemas

Settings Manifest Protocol

Declarative description of a single namespace of platform settings

(e.g. mail, branding, feature_flags). Modelled on Apple's

Settings.bundle/Root.plist PreferenceSpecifiers — a small, closed

set of specifier types that the system-owned renderer turns into a

uniform Settings page.

Storage for values is the generic sys_setting K/V table; manifests

themselves are NEVER persisted — they ship with plugin code.

See ADR-0007 (Settings Manifest + K/V Store + Resolver).

Resolution order (handled by SettingsService.get):

  1. process.env override (source='env', locked=true)

  2. sys_setting scope=tenant

  3. sys_setting scope=user

  4. manifest specifier.default

Source: packages/spec/src/system/settings-manifest.zod.ts

TypeScript Usage

import { ResolvedSettingValue, SettingsActionResult, SettingsManifest, SettingsNamespacePayload, Specifier, SpecifierHandler, SpecifierOption, SpecifierScope, SpecifierType } from '@objectstack/spec/system';
import type { ResolvedSettingValue, SettingsActionResult, SettingsManifest, SettingsNamespacePayload, Specifier, SpecifierHandler, SpecifierOption, SpecifierScope, SpecifierType } from '@objectstack/spec/system';

// Validate data
const result = ResolvedSettingValue.parse(data);

ResolvedSettingValue

Properties

PropertyTypeRequiredDescription
valueanyEffective value (post-resolution)
sourceEnum<'env' | 'global' | 'tenant' | 'user' | 'default'>Resolution source
lockedbooleanCannot be overridden from UI
lockedReasonstringoptionalReason for the lock (UI tooltip)
cascadeChainObject[]optionalFull cascade trace (env → global → tenant → user → default)

SettingsActionResult

Properties

PropertyTypeRequiredDescription
okbooleanSuccess flag
messagestringoptionalToast message
severityEnum<'info' | 'success' | 'warning' | 'error'>optional
detailsanyoptionalOptional structured detail (renderer-defined)

SettingsManifest

Properties

PropertyTypeRequiredDescription
namespacestringNamespace (snake_case, globally unique)
versionintegeroptionalManifest schema version
labelstringDisplay label
iconstringoptionalIcon (Lucide)
descriptionstringoptionalShort description
helpTextstringoptionalMarkdown help text shown above specifiers
scopeEnum<'global' | 'tenant' | 'user'>optionalDefault scope for specifiers
readPermissionstringoptionalPermission required to read
writePermissionstringoptionalPermission required to write
categorystringoptionalSettings hub category
ordernumberoptionalDisplay order
specifiersObject[]Page contents (ordered)
visiblestring | ObjectoptionalWhole-manifest visibility
featureFlagstringoptionalGate manifest visibility on a feature flag
betabooleanoptionalShow a Beta chip on the page

SettingsNamespacePayload

Properties

PropertyTypeRequiredDescription
manifestObject
valuesRecord<string, Object>Effective values keyed by specifier.key

Specifier

Properties

PropertyTypeRequiredDescription
typeEnum<'group' | 'child_pane' | 'info_banner' | 'title_value' | 'text' | 'textarea' | 'password' | 'email' | 'url' | 'phone' | 'number' | 'toggle' | 'select' | 'radio' | 'multiselect' | 'slider' | 'color' | 'json' | 'action_button'>Specifier variant
idstringoptionalStable identifier (snake_case)
keystringoptionalStorage key (snake_case)
labelstringDisplay label
descriptionstringoptionalHelp text
iconstringoptionalIcon name (Lucide)
defaultanyoptionalDefault value
visiblestring | ObjectoptionalVisibility expression
requiredbooleanoptionalRequired field
encryptedbooleanoptionalEncrypt value at rest (forced true for password)
scopeEnum<'global' | 'tenant' | 'user'>optionalOverride manifest scope for this key
availableScopesEnum<'global' | 'tenant' | 'user'>[]optionalScopes allowed to override this specifier
lockablebooleanoptionalAllow upper-scope locking of this specifier
readPermissionstringoptionalPermission required to read this specifier
writePermissionstringoptionalPermission required to write this specifier
deprecatedbooleanoptionalMark deprecated
replacedBystringoptionalReplacement key (used when deprecated=true)
optionsObject[]optionalOptions for select/radio/multiselect
minnumberoptional
maxnumberoptional
stepnumberoptional
minLengthintegeroptional
maxLengthintegeroptional
patternstringoptionalRegex pattern (text only)
rowsintegeroptional
handlerObject | Object | ObjectoptionalAction handler (action_button)
childNamespacestringoptionalSub-namespace (child_pane)
bannerTextstringoptionalMarkdown body (info_banner)
bannerSeverityEnum<'info' | 'success' | 'warning' | 'error'>optional

SpecifierHandler

Union Options

This schema accepts one of the following structures:

Option 1

Properties

PropertyTypeRequiredDescription
kindstring
methodEnum<'GET' | 'POST' | 'PUT' | 'DELETE' | 'PATCH'>
urlstringEndpoint URL; supports ${...} interpolation
bodyRecord<string, any>optionalOptional JSON body; supports ${...} interpolation
confirmTextstringoptionalConfirm dialog text before invoking (omit = no confirm)

Option 2

Properties

PropertyTypeRequiredDescription
kindstring
namestringRegistered action machine name
paramsRecord<string, any>optional
confirmTextstringoptionalDisplay label (plain string; i18n keys are auto-generated by the framework)

Option 3

Properties

PropertyTypeRequiredDescription
kindstring
urlstringTarget URL or in-app route
targetEnum<'_self' | '_blank'>


SpecifierOption

Properties

PropertyTypeRequiredDescription
valuestring | number | booleanStored value
labelstringDisplay label
descriptionstringoptionalOptional helper text
iconstringoptionalOptional Lucide icon name

SpecifierScope

Allowed Values

  • global
  • tenant
  • user

SpecifierType

Allowed Values

  • group
  • child_pane
  • info_banner
  • title_value
  • text
  • textarea
  • password
  • email
  • url
  • phone
  • number
  • toggle
  • select
  • radio
  • multiselect
  • slider
  • color
  • json
  • action_button

On this page