Runtime configuration

woml.runtime.json is optional. Safe defaults keep local use simple.

JSON
{
  "schemaVersion": 1,
  "deploymentName": "order-automation",
  "statePath": "./data/state.sqlite",
  "public": { "host": "127.0.0.1", "port": 3000 },
  "admin": { "host": "127.0.0.1", "port": 3001 },
  "logging": {
    "format": "text",
    "level": "info",
    "directory": "./logs"
  },
  "workers": 4,
  "shutdownTimeoutMs": 30000,
  "observability": { "health": true, "metrics": true },
  "retention": {
    "enabled": true,
    "succeededAfterDays": 30,
    "failedAfterDays": 90,
    "cancelledAfterDays": 30,
    "maintenanceHourUtc": 3
  },
  "backup": { "directory": "./backups" }
}
FieldConstraints and meaning
schemaVersionRequired and exactly 1.
deploymentNameLowercase segmented identity, maximum 128.
statePathDurable state path, relative to the config file when relative.
publicTrigger listener host/port.
adminLocal operations listener host/port; production admin remains loopback-only.
logging.formattext or json.
logging.levelerror, warn, info, or debug.
logging.directoryRuntime log destination.
workers1–256 Bun worker capacity.
shutdownTimeoutMs1,000–300,000 ms graceful drain.
observability.health, .metricsEnable local operations endpoints.
retention.enabledEnables automatic retention.
Retention day fields1–3,650 days per terminal outcome.
maintenanceHourUtc0–23.
backup.directoryConfigured backup directory.

Precedence is explicit CLI option, reviewed WOML_RUNTIME_* environment variable, config file, then safe default.