{% extends "mirrorwall/base.html" %} {% from "mirrorwall/components.html" import table %} {% block title %}Settings — PromptCadence{% endblock %} {% block content %}

Settings

Only what can change while the server runs. Everything else — the bind, the LoadCoach credential, the approval gates, the ceilings, the tool roots and the tiers — lives in config.toml or the environment and is refused here by name. A change is applied by the running worker at its next lease reap, and reaches every process sharing this database.

A key set in the environment beats a stored value (configuration standards §7): defaults → file → database → env → CLI. A stored value that cannot take effect is shown below as shadowed rather than quietly dropped.

{% if saved %}

Saved. The running worker applies the change at its next lease reap.

{% endif %} {% if not may_change %}

This session holds the read scope and not admin, so the form is not shown. Looking at the effective configuration and changing it are deliberately separate scopes.

{% set columns = [{"label": "Key"}, {"label": "Effective"}, {"label": "Configured"}, {"label": "Source"}] %} {% set rows = [] %} {% for key in keys %} {% set _ = rows.append([ key, document.settings[key], document.definitions[key].configured, document.definitions[key].shadowed_by or document.definitions[key].source ]) %} {% endfor %} {{ table(columns, rows, caption="Runtime-changeable settings", complete=true, row_count=keys | length) }} {% else %}
{% for key in keys %} {% set definition = document.definitions[key] %}

{{ definition.description }} Configured: {{ definition.configured }} · range {{ definition.minimum }}–{{ definition.maximum }}. {% if definition.shadowed_by %}Stored value {{ definition.stored }} is shadowed by {{ definition.shadowed_by }} and does nothing until that variable is unset.{% elif definition.source == "database" %}Stored here, and effective.{% endif %}

{% endfor %}
{% endif %}

Config-only keys

Refused with FORBIDDEN naming the key when sent to PUT /api/v1/settings: exposure, egress, credentials, containment, retention and spend. The ceilings are among them deliberately — raising one is an approval with an approver on the record, never a form.

{% endblock %}