put_api_management_v1_workspaces_slug_state
const url = 'https://example.com/api/management/v1/workspaces/example/state';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"agent_profiles":[{"allow_tier_escalation":true,"avatar_kind":"example","avatar_value":"example","capability_allowlist":["example"],"color":"example","default_agent_type":"example","description":"example","effort_default":"example","enabled":true,"execution_mode":"example","fixed_model":"example","interactive_approval":true,"max_subagents":1,"max_turns":1,"mcp_memory_create":true,"mcp_ops_per_hour_cap":1,"mcp_ops_per_task_cap":1,"memory_policy":"example","model_policy":"example","model_tier":"example","name":"example","persona_prompt":"example","placement_policy":"example","post_flight_checks":"example","pr_template":"example","pre_flight_checks":"example","resource_class":"normal","retry_policy":"example","review_required":true,"script_allowlist":["example"],"slug":"example","tags":["example"],"tool_approval_deny_minutes":1,"autonomy_level":1,"autonomy_overrides":"example","workspace_default":true}],"ai_credentials":[{"key":"example","label":"example","provider":"example"}],"budget":{"api_mode_controls":"example","critical_threshold_percent":1,"hard_stop":true,"monthly_cap_usd":1,"provider_monthly_caps_usd":"example","threshold_alerts_percent":[1],"warning_threshold_percent":1},"capabilities":{"mcps":{"additionalProperty":{"config":{"additionalProperty":"example"},"description":"example","enabled":true,"label":"example"}},"skills":{"additionalProperty":{"config":{"additionalProperty":"example"},"description":"example","enabled":true,"label":"example"}}},"git_credentials":[{"auth_type":"example","credential_data":"example","git_provider":"example","label":"example"}],"invites":[{"email":"example","role":"example"}],"mailbox_credentials":[{"allowed_login_providers":["example"],"email":"example","imap_host":"example","imap_port":1,"label":"example","password_secret_ref":"example","provider":"example","use_tls":true,"username":"example"}],"marketplace_installs":[{"adopt_namespace":"example","namespace_entity":"example","optional_members":["example"],"project_key":"example","relocate":true,"resource_mappings":[{"binding_name":"example","grant_write":true,"requirement_kind":"example","resource_name":"example"}],"schema":"example","slug":"example","version":"example"}],"members":[{"admin":true,"approved":true,"display_name":"example","email":"example","role":"example"}],"oauth_credentials":[{"access_token":"example","account_email":"example","expires_at":"2026-04-15T12:00:00Z","id_token":"example","provider":"example","refresh_token":"example"}],"projects":[{"agent_commit_co_author":true,"auto_developer_agent_type":"example","auto_developer_enabled":true,"auto_issue_debate_enabled":true,"automations":[{"agent_profile_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","autonomy_override":1,"candidate_profile_ids":["2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"],"close_source_issue":true,"completion_action":"close","denied_tools":["example"],"enabled":true,"environment_scope":"all","kind":"pr_review","pipeline_config":"example","post_completion_comment":true,"review_enabled":true,"severity_min":"critical","source_filter":"example","trigger":"webhook","webhook_secret":"example","workflow_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}],"closeout_config":{"memory":true,"project_docs":{"condition":"if_touched","enabled":true,"globs":["example"]},"user_docs":{"condition":"if_touched","enabled":true,"globs":["example"],"langs":["example"]},"wiki":{"condition":"if_touched","enabled":true}},"git_credential_label":"example","git_default_branch":"example","git_provider":"example","git_repo_url":"example","git_repo_url_edit_intent":"keep_private","issue_close_policy":"example","key":"example","mcp_caps":{"deploy_per_project_day":1,"deploy_per_task_per_tool":1,"ops_per_profile_hour":1,"ops_per_project_day":1,"ops_per_task_per_tool":1,"ops_per_task_total":1,"ops_per_workspace_day":1,"subtask_children_per_parent":1},"memory_governance_policy":{"personal":{"auto_publish":true,"require_review":true,"retention_days":1},"project":{"auto_publish":true,"require_review":true,"retention_days":1},"workspace":{"auto_publish":true,"require_review":true,"retention_days":1}},"name":"example","pipeline_config":"example","review_enabled":true}],"read_namespace_bindings":[{"app":"example","backend_function":"example","entitlement_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","expect":{"entity":"example","namespace_handle":"example"},"operation":"example","script":"example"}],"repo_sync":{"auto_push":true,"branch":"example","credential_resource":"example","repo_url":"example","sync_mode":"example","url_edit_intent":"keep_private"},"resources":[{"config":"example","kind":"example","name":"example","secret":"example"}],"schedules":[{"agent_profile_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","agent_type":"example","cadence":"example","config":"example","interval_minutes":1,"key":"example","next_run_at":"2026-04-15T12:00:00Z","project_key":"example","prompt":"example","timezone":"example","title":"example"}],"task_scopes":{"by_agent_type":{"additionalProperty":["example"]},"by_project":{"additionalProperty":["example"]},"default_mcp_allowlist":["example"]},"tasks":[{"agent_profile_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","agent_type":"example","closeout":{"memory":true,"project_docs":{"condition":"if_touched","enabled":true,"globs":["example"]},"user_docs":{"condition":"if_touched","enabled":true,"globs":["example"],"langs":["example"]},"wiki":{"condition":"if_touched","enabled":true}},"config":{"additionalProperty":"example"},"issue_id":"example","issue_url":"example","key":"example","project_key":"example","prompt":"example","title":"example"}],"variables":[{"is_secret":true,"key":"example","project_key":"example","value":"example"}],"workflow_schedules":[{"cadence":"example","interval_minutes":1,"key":"example","next_run_at":"2026-04-15T12:00:00Z","project_key":"example","timezone":"example","workflow":"example"}],"workflow_templates":[{"config":{"additionalProperty":"example"},"key":"example","name":"example","project_key":"example","template":"example"}],"workflow_triggers":[{"config":"example","enabled":true,"key":"example","kind":"example","project_key":"example","workflow":"example"}],"workspace":{"agent_commit_co_author":true,"mcp_caps":{"deploy_per_project_day":1,"deploy_per_task_per_tool":1,"ops_per_profile_hour":1,"ops_per_project_day":1,"ops_per_task_per_tool":1,"ops_per_task_total":1,"ops_per_workspace_day":1,"subtask_children_per_parent":1},"message_retention_days":1,"name":"example","owner_email":"example"}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/management/v1/workspaces/example/state \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "agent_profiles": [ { "allow_tier_escalation": true, "avatar_kind": "example", "avatar_value": "example", "capability_allowlist": [ "example" ], "color": "example", "default_agent_type": "example", "description": "example", "effort_default": "example", "enabled": true, "execution_mode": "example", "fixed_model": "example", "interactive_approval": true, "max_subagents": 1, "max_turns": 1, "mcp_memory_create": true, "mcp_ops_per_hour_cap": 1, "mcp_ops_per_task_cap": 1, "memory_policy": "example", "model_policy": "example", "model_tier": "example", "name": "example", "persona_prompt": "example", "placement_policy": "example", "post_flight_checks": "example", "pr_template": "example", "pre_flight_checks": "example", "resource_class": "normal", "retry_policy": "example", "review_required": true, "script_allowlist": [ "example" ], "slug": "example", "tags": [ "example" ], "tool_approval_deny_minutes": 1, "autonomy_level": 1, "autonomy_overrides": "example", "workspace_default": true } ], "ai_credentials": [ { "key": "example", "label": "example", "provider": "example" } ], "budget": { "api_mode_controls": "example", "critical_threshold_percent": 1, "hard_stop": true, "monthly_cap_usd": 1, "provider_monthly_caps_usd": "example", "threshold_alerts_percent": [ 1 ], "warning_threshold_percent": 1 }, "capabilities": { "mcps": { "additionalProperty": { "config": { "additionalProperty": "example" }, "description": "example", "enabled": true, "label": "example" } }, "skills": { "additionalProperty": { "config": { "additionalProperty": "example" }, "description": "example", "enabled": true, "label": "example" } } }, "git_credentials": [ { "auth_type": "example", "credential_data": "example", "git_provider": "example", "label": "example" } ], "invites": [ { "email": "example", "role": "example" } ], "mailbox_credentials": [ { "allowed_login_providers": [ "example" ], "email": "example", "imap_host": "example", "imap_port": 1, "label": "example", "password_secret_ref": "example", "provider": "example", "use_tls": true, "username": "example" } ], "marketplace_installs": [ { "adopt_namespace": "example", "namespace_entity": "example", "optional_members": [ "example" ], "project_key": "example", "relocate": true, "resource_mappings": [ { "binding_name": "example", "grant_write": true, "requirement_kind": "example", "resource_name": "example" } ], "schema": "example", "slug": "example", "version": "example" } ], "members": [ { "admin": true, "approved": true, "display_name": "example", "email": "example", "role": "example" } ], "oauth_credentials": [ { "access_token": "example", "account_email": "example", "expires_at": "2026-04-15T12:00:00Z", "id_token": "example", "provider": "example", "refresh_token": "example" } ], "projects": [ { "agent_commit_co_author": true, "auto_developer_agent_type": "example", "auto_developer_enabled": true, "auto_issue_debate_enabled": true, "automations": [ { "agent_profile_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "autonomy_override": 1, "candidate_profile_ids": [ "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" ], "close_source_issue": true, "completion_action": "close", "denied_tools": [ "example" ], "enabled": true, "environment_scope": "all", "kind": "pr_review", "pipeline_config": "example", "post_completion_comment": true, "review_enabled": true, "severity_min": "critical", "source_filter": "example", "trigger": "webhook", "webhook_secret": "example", "workflow_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" } ], "closeout_config": { "memory": true, "project_docs": { "condition": "if_touched", "enabled": true, "globs": [ "example" ] }, "user_docs": { "condition": "if_touched", "enabled": true, "globs": [ "example" ], "langs": [ "example" ] }, "wiki": { "condition": "if_touched", "enabled": true } }, "git_credential_label": "example", "git_default_branch": "example", "git_provider": "example", "git_repo_url": "example", "git_repo_url_edit_intent": "keep_private", "issue_close_policy": "example", "key": "example", "mcp_caps": { "deploy_per_project_day": 1, "deploy_per_task_per_tool": 1, "ops_per_profile_hour": 1, "ops_per_project_day": 1, "ops_per_task_per_tool": 1, "ops_per_task_total": 1, "ops_per_workspace_day": 1, "subtask_children_per_parent": 1 }, "memory_governance_policy": { "personal": { "auto_publish": true, "require_review": true, "retention_days": 1 }, "project": { "auto_publish": true, "require_review": true, "retention_days": 1 }, "workspace": { "auto_publish": true, "require_review": true, "retention_days": 1 } }, "name": "example", "pipeline_config": "example", "review_enabled": true } ], "read_namespace_bindings": [ { "app": "example", "backend_function": "example", "entitlement_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "expect": { "entity": "example", "namespace_handle": "example" }, "operation": "example", "script": "example" } ], "repo_sync": { "auto_push": true, "branch": "example", "credential_resource": "example", "repo_url": "example", "sync_mode": "example", "url_edit_intent": "keep_private" }, "resources": [ { "config": "example", "kind": "example", "name": "example", "secret": "example" } ], "schedules": [ { "agent_profile_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "agent_type": "example", "cadence": "example", "config": "example", "interval_minutes": 1, "key": "example", "next_run_at": "2026-04-15T12:00:00Z", "project_key": "example", "prompt": "example", "timezone": "example", "title": "example" } ], "task_scopes": { "by_agent_type": { "additionalProperty": [ "example" ] }, "by_project": { "additionalProperty": [ "example" ] }, "default_mcp_allowlist": [ "example" ] }, "tasks": [ { "agent_profile_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "agent_type": "example", "closeout": { "memory": true, "project_docs": { "condition": "if_touched", "enabled": true, "globs": [ "example" ] }, "user_docs": { "condition": "if_touched", "enabled": true, "globs": [ "example" ], "langs": [ "example" ] }, "wiki": { "condition": "if_touched", "enabled": true } }, "config": { "additionalProperty": "example" }, "issue_id": "example", "issue_url": "example", "key": "example", "project_key": "example", "prompt": "example", "title": "example" } ], "variables": [ { "is_secret": true, "key": "example", "project_key": "example", "value": "example" } ], "workflow_schedules": [ { "cadence": "example", "interval_minutes": 1, "key": "example", "next_run_at": "2026-04-15T12:00:00Z", "project_key": "example", "timezone": "example", "workflow": "example" } ], "workflow_templates": [ { "config": { "additionalProperty": "example" }, "key": "example", "name": "example", "project_key": "example", "template": "example" } ], "workflow_triggers": [ { "config": "example", "enabled": true, "key": "example", "kind": "example", "project_key": "example", "workflow": "example" } ], "workspace": { "agent_commit_co_author": true, "mcp_caps": { "deploy_per_project_day": 1, "deploy_per_task_per_tool": 1, "ops_per_profile_hour": 1, "ops_per_project_day": 1, "ops_per_task_per_tool": 1, "ops_per_task_total": 1, "ops_per_workspace_day": 1, "subtask_children_per_parent": 1 }, "message_retention_days": 1, "name": "example", "owner_email": "example" } }'Apply workspace state through the authenticated management service.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Workspace management slug
Request Bodyrequired
Section titled “Request Bodyrequired”object
#1152 — agent-profile runbooks, upserted per slug. The READ side of this
document exposes agent_profiles (#998); this is the write contract, so
a provisioning run can seed the WHO of a launch (harness, model, effort,
allowlist tier, closeout/check gates) alongside the projects and credentials
it already seeds. Additive like every list here: a profile absent from the
payload is never deleted server-side. Requires
management:agent_profiles:write.
The desired state of ONE agent profile. Identified by the URL {key} (its
slug) on the item route, or by slug inside the declarative state document.
object
SC-3 — may a task under this profile request a stronger tier? Absent preserves
the current value (update) / false (create). Not on the MCP write schema.
ADR 0045 §3.6 — default reasoning effort
(minimal | low | medium | high | max). Optional; preserves the current
value on update, leaves None (inherit the runner default) on create.
Issue #364 / ADR 0039 (D7); #708 who-3 — normal | workflow (ultracode
RETIRED to the effort axis). Optional; preserves the current value on update,
defaults to normal on create.
ADR 0045 §3.2 — opt this profile into the interactive tool-approval gate
(resolve_interactive_approvals_for_run). Optional; preserves the current
value on update, defaults to false on create. #708 W5 wired this WRITE
path (it was read-only before — the create/update never persisted it).
#838 — per-profile DEFAULT for the subagent concurrency ceiling (migration
358; 1..=64). The middle tier of task.config.max_subagents ?? profile ?? workspace ?? (no env). DOUBLE-Option with the same semantics as
[Self::max_turns]: absent preserves the current value on update / leaves
NULL on create; an explicit null clears it; a value sets it. “Absent =
unchanged” is load-bearing — the simple profiles tab sends a partial payload
and must never null a stored default (the #858 W4a ops-cap pattern).
#1018 — per-profile DEFAULT for the harness turn limit (migration 340,
positive). DOUBLE-Option: absent preserves the current value on update / leaves
NULL (no default — the runner’s 500 applies) on create; an explicit null
clears it; a value sets it. “Absent = unchanged” is load-bearing — the
simple profiles tab sends a partial payload, and it must never null a
stored default (the #858 W4a ops-cap pattern).
ADR 0049 (#547 / #548) — opt-in gate for the agent memory.create MCP
tool. Optional; preserves the current value on update, defaults to false
(fail-closed) on create. A workspace admin sets this on the profile editor
to open the unreviewed direct-write path.
#858 W4a — per-profile override of the profile-hourly MCP Ops budget
(migration 320; range 1–1000). Same DOUBLE-Option semantics as
mcp_ops_per_task_cap. The workspace-daily Ops ceiling stays fixed.
#858 W4a — per-profile override of the per-task/per-tool MCP Ops budget
(migration 320; range 1–500). DOUBLE-Option: absent preserves the current
value on update / leaves NULL (the ADR 0028 default, 10) on create; an
explicit null clears the override back to the default; a value sets it.
Admin-gated — the profile PUT already requires workspace admin.
SC-3 — the calibrator tier of a model_policy = "tier" profile. Required under
that policy, dropped under any other; absent preserves the current value.
SC-6 — the profile tier of the runner placement policy
({on_no_runner, queue_timeout_minutes}, the projects.placement_policy shape).
DOUBLE-Option: absent preserves the current value / NULL on create; null
clears it (inherit); a document sets it after validate_policy_document.
#1176 — the profile’s RESOURCE CLASS (migration 361; normal | heavy).
The middle tier of task.config.resource_class ?? profile ?? workspace ?? normal.
A class is the profile’s statement about how much MACHINE its work needs:
the container’s memory cap and, inseparably, how many of the workspace’s
concurrency slots the task holds. Declaring heavy therefore does not
raise the host’s peak footprint — it trades parallelism for room.
DOUBLE-Option with the same semantics as [Self::max_turns]: absent
preserves the current value on update / leaves NULL on create; an explicit
null clears it; a value sets it. “Absent = unchanged” is load-bearing —
the simple profiles tab sends a partial payload and must never null a
stored declaration.
The script-run allowlist. Optional; absent preserves the current value on update
/ leaves None (OPEN — every script allowed) on create; a value (incl. [],
fail-closed) sets it. Mirrors capability_allowlist. #708 W9 wired this so a
workspace manifest round-trips it — the manifest apply supplies a fail-closed
Some([]) default (never the open None) when the manifest omits it.
#1175 (migration 363) — the profile’s TOOL-GATE deny budget in minutes,
the middle tier of task.config.tool_approval_deny_minutes ?? profile ?? workspace ?? 1440.
It governs ONLY the deny timeout policy, which a caller must name
explicitly. hold — the default for every runner-raised gate since #1164 —
carries no deadline, and no value here can give it one.
Range [5, 43200], enforced by the migration-363 CHECK and refused BY NAME
at write time rather than clamped, so a stored value is always the value
that applies. DOUBLE-Option, same semantics as [Self::max_turns].
Promote this profile to the workspace default (true), clear the
workspace default entirely (false), or leave it untouched (absent).
#242/ADR 0033 — a task with no agent_profile_id resolves to the
workspace default, so this is the WHO of every unpinned launch.
object
Optional MCP + skill capability map, mirroring the workspace
manifest shape from ADR-0007. When present, the Management API
applies it via the same apply_capabilities path used by
POST /api/workspace/apply-manifest. Absent keys are no-ops —
existing callers that don’t send this field keep working
unchanged. See bw-infra docs/38 §4.6.
object
object
One MCP or skill override inside a manifest. Mirrors the schema
described in docs/schemas/supacloud-workspace.schema.json.
object
object
object
One MCP or skill override inside a manifest. Mirrors the schema
described in docs/schemas/supacloud-workspace.schema.json.
object
object
object
object
object
#1214 — official-catalog listings this workspace carries, by slug.
ADDITIVE like every list here, and here that is load-bearing rather than
conventional: there is no uninstall path at all, so a removed entry cannot
be honoured even in principle. Requires management:credentials:write —
an install materialises the listing’s resources into the workspace.
One OFFICIAL-catalog listing this workspace carries.
ADDITIVE, deliberately: a listing that disappears from the document is NOT uninstalled, because no uninstall path exists (neither route nor query, measured 2026-08-31). Saying so here is the point — a document that reads as a full desired state while only ever adding is the more dangerous shape.
object
#1549 — the HANDLE of an existing database namespace of this workspace the
install adopts for the listing’s namespace (e.g. ns_bw_workflows for a
listing whose db/namespace.yaml declares ns_finance). Handles, not ids,
for the same portability reason as resource names. Rides
ResourceMappings.adopt_namespace into the very validation the browser
install runs; absent changes nothing.
#1549 — the entity the installed workflows bind an entity-isolated listing
namespace with (ResourceMappings.namespace_entity). Absent leaves them
unbound.
#1333 — the OPTIONAL bundle members to materialise (ADR 0072 D7). Absent installs the required set. A mapping on an optional member’s binding hole is refused unless that member is selected here. Honoured on INSTALL only: an update never grows the selection, exactly as the marketplace service states for every other caller.
#1549 — the project the listing’s workflow members land in, by the same
project key a workflows / workflow_triggers entry names (a trigger
resolves its target workflow by name INSIDE its project_key, so the
install must land there). Rides ResourceMappings.target_project_id.
Absent: the workspace’s only project, or a created “Marketplace Installs”
project when it has none; a workspace with several projects is refused by
name, never guessed. On an existing install it must name the project the
install already places its workflows in, unless relocate is true.
#1549 — true RELOCATES an existing install to project_key: the
workflows the install created (and its recorded target) move to that project
of the same workspace, audited as marketplace_install_relocated, before the
entry’s normal install/update continues there. Refused by name unless every
owned workflow still carries the listing’s catalog mark, has never run, and
has no enabled trigger, active schedule, project-credential schedule or
project automation arm; the target project must hold no workflow of the
same name. The App stays workspace-wide; only the workflows move. A
relocation to where the install already is changes nothing. Requires
project_key. Absent or false: an existing install never moves. An
action, not state, so the READ side does not report it.
#1333 / ADR 0072 D8-Ausnahme — the resource bindings this listing is to CREATE or WIDEN, named by resource NAME so the document stays portable.
A present, NON-EMPTY list makes the apply a SUBMITTED grant (D8): it may
fill a workflow member’s ADR 0058 §7 binding hole and arm its write half.
Absent or empty stays STORED — the apply may only preserve bindings that
are already in force, never create or widen one. The asymmetry is
deliberate: an IaC template that renders an unset list as [] must not
retract the bindings a running install carries, so “empty” is read as
“send nothing”, not as an explicit “bind nothing”.
One resource binding a management document asks an install to CREATE or WIDEN.
The browser install body names a resource_id (a UUID minted per instance);
a portable document cannot carry one, for the very reason
[ManagementRepoSyncSpec::credential_resource] states one block up: ids apply
only to the instance they were minted against. This keeps the document in the
vocabulary it already uses — the NAME of a workspace resource declared in its
own resources block — and the apply resolves the name to this instance’s id.
object
The in-guest binding NAME this mapping supplies authority for, when it
fills a workflow member’s ADR 0058 §7 hole. None is the pre-#1313
per-kind mapping, which fills no hole.
The WRITE grant for binding_name. None and false are the same safe
answer: only true asks for write, and only where the requirement asks it
too (the effective allow_write is the AND of the two).
The requirement KIND this mapping answers (seafile_webdav,
postgresql, …) — the same token the manifest requirement carries.
The NAME of a workspace resource holding the authority — never a UUID. An unknown or ambiguous name is an ERROR, not a silent non-binding.
#1313 / ADR 0073 D2 — the postgresql schema a schema_per_workspace
listing’s migrations apply into, for a workspace that has no recorded
namespace row yet.
The catalog ships a neutral placeholder and the INSTALL REQUEST names the
real schema, exactly as ResourceMappings.schema does for the browser
wizard (ADR 0073 D2). Absent or empty is the pre-#1313 shape and changes
nothing: a listing that does not opt in keeps its manifest literal, and an
opted-in listing with no recorded row is refused by name rather than
guessed. The value is never defaulted to a fixed schema name — the wrong
schema would write one tenant’s data into another’s.
skip_serializing_if matches ResourceMappings.schema: an absent schema
is “no opinion”, not an explicit erasure.
The catalog slug (scan-capture, finance-overview-app, …), resolved
against the official source. Same reason as credential_resource above:
item ids are per-instance, slugs are not.
Pin to one version. Absent means “track the newest installable version”, which is what a provisioning run wants — re-applying then carries a catalog update into the workspace.
object
object
object
#1546 G1 (mig 679) — the project tier of the agent-commit co-author setting.
Absent leaves it untouched; null inherits the workspace tier. Routed through
the same service (and audit row) as the browser project PUT.
#708 X2b — the PR-flow arming fields the management apply honors. auto_developer_enabled
arms the pr_review automation arm; auto_developer_agent_type stamps its
source_filter.harness. Other PR-flow configuration belongs to the automation arm.
#708 M1/X5 — compatibility refusal for the unsupported standalone issue-debate lane. Council is a per-stage flag. Setting this field true returns422 from apply_project; false or absent is accepted for backward-compatible manifests.
#1161 D2 — the project’s AUTOMATION ARMS, reaching parity with the browser project
PUT’s automations block. This is the config home of review_enabled (the forensic
audit tail, mig 231) and pipeline_config (the return-to-sender loop’s
max_rounds / max_cost_usd ceilings and per-stage overrides). Management and
browser apply use the same validated automation contract.
ONE SOURCE, not a second truth (the #1152 rule for agent profiles applies verbatim):
each entry is the very SaveAutomationInput the browser PUT deserializes, applied
through the very project_automations::upsert_automation the browser calls — so the
Class-B PATCH-merge, the kind validation, the autonomy clamp and the workflow
RECONCILE (which materializes the arm’s template) are shared, not re-implemented.
Absent / null leaves every arm untouched.
What a save supplies for one automation. webhook_secret = None keeps any
stored secret on update (the persistence COALESCE) — a config edit need not
re-type it. autonomy_override is the REQUESTED level; the service clamps it
to the workspace ceiling before persist.
object
#534 WS-2 — the multi-agent work-lane candidate pool (backlog/simple lane).
Some(None) clears; Some(Some([])) = the All wildcard (every keyed
workspace profile, dynamic); Some(Some([ids])) = an explicit set; an omitted
key (outer None) keeps the stored pool.
#538 feinschliff — the dev-pipeline knobs JSONB (return_to_sender, convergence_level, max_rounds, max_cost_usd, per-stage overrides; mig 231).
#708 C1 — the two ADDITIVE completion booleans (post the closing comment × close/
transition the source issue). An omitted key keeps the stored value; when set, the write
derives + dual-writes completion_action (lossy for “silent close”).
#538 feinschliff — the Review toggle (the gated audit tail).
Write-only HMAC secret; an omitted/empty value keeps the stored secret (the persistence COALESCE), a non-empty value overwrites it.
#794 Stretch — selecting an existing workflow (including a Marketplace
install) binds it directly to this arm. null restores the platform
managed template only when the arm was previously selected; omitted keeps
the current binding.
#708 M1 (K-06) — the project-tier tiered standard-closeout override (mig 283),
reaching parity with the browser project PUT so an IaC apply can set it. A sparse
JSONB bag documented by the CloseoutConfigPatch schema; on apply it is
shape-validated (models::closeout::validate_patch) then merged into the applied
project config exactly like the browser PUT (persisted via
queries::projects::set_closeout_config). null / absent leaves the column
untouched (the project inherits the workspace default). The management owner token
acts as the workspace owner, so no additional per-field gate applies.
object
Gates the Tier-0 closeout MEMORY proposal. None inherits the next tier.
Public read/edit/save preserves private connection bytes unless replacement is explicit.
SC-22 (parity with the browser project save) — the project-level issue close policy:
on_completion | merged_pr_only. Applied through the SAME sc-svc-projects
apply_issue_close_policy service the browser save uses: 400 for another value, 422
for autonomy >= 75 + an auto-merge policy + on_completion. null / absent leaves
the stored policy untouched; an unchanged value is an idempotent no-op. (An
Option field deserializes an absent key as None, so no #[serde(default)].)
SC-23 (M2M parity, SCG-047) — the project’s SPARSE agent tool-budget override
(projects.mcp_caps: per-task, per-profile-hour and project-day Ops/Deploy budgets).
Routed through the very set_project_mcp_caps service the browser PUT calls
(validation and the project_mcp_caps_set audit row live there). null / absent
leaves the stored override untouched; an unchanged value is an idempotent no-op.
object
Deploy calls one project may make per rolling 24 h (default: no project bucket).
Deploy calls one task may make per Deploy tool (built-in 5).
Ops calls one agent profile may make per rolling hour (instance default 30).
Ops calls one project may make per rolling 24 h (default: the instance workspace-daily default times the autonomy factor).
Ops calls one task may make per Ops tool (built-in 10).
Ops calls one task may make over all Ops tools together (built-in 40).
WORKSPACE ONLY, owner-written: the workspace’s rolling-24 h Ops ceiling
(instance default 100). A raise is bounded by the plan’s mcp.ops_daily_max.
WORKSPACE ONLY: concurrent delegated children one parent task may have in
flight (built-in 10). Replaces the hub-wide SUBTASK_MAX_CHILDREN_PER_PARENT
env var (SCG-146).
#708 W13 (M2M parity) — the project-tier SPARSE memory-governance override (mig 289),
reaching parity with the browser project PUT so an IaC apply can set it. A sparse JSONB
bag documented by the ProjectMemoryGovernanceOverride schema; on apply it is routed
through the very sc-svc-projects apply_memory_governance_policy service the browser
PUT calls (shape-validated, then persisted via queries::projects::set_memory_governance_policy),
so the session door and the M2M door share ONE validation + write path rather than a
parallel validate+setter pair. null / absent leaves the column untouched (the project
keeps inheriting the workspace policy); there is no reset-to-NULL through this door,
exactly like the closeout_config sibling above.
object
The governance rule for ONE memory scope: whether new memories of that scope skip
the review queue (auto_publish), whether they must be human-reviewed
(require_review), and how long they are retained before the decay sweep may
archive them (retention_days, 0 = keep forever).
auto_publish and require_review are intentionally NOT collapsed into one flag:
the conservative default is “review required, not auto-published”, and a future
“auto-published BUT still logged for review” mode keeps both axes meaningful. The
validation below rejects the contradictory auto_publish && require_review combo.
object
New memories of this scope skip the review queue and land live immediately.
New memories of this scope must be human-reviewed before they go live.
Days a memory of this scope is retained before the decay sweep may archive it;
0 keeps it forever. Defaults per scope: shared scopes (workspace/project)
start at [DEFAULT_SHARED_RETENTION_DAYS] (#1228), personal at 0.
not matching
The governance rule for ONE memory scope: whether new memories of that scope skip
the review queue (auto_publish), whether they must be human-reviewed
(require_review), and how long they are retained before the decay sweep may
archive them (retention_days, 0 = keep forever).
auto_publish and require_review are intentionally NOT collapsed into one flag:
the conservative default is “review required, not auto-published”, and a future
“auto-published BUT still logged for review” mode keeps both axes meaningful. The
validation below rejects the contradictory auto_publish && require_review combo.
object
New memories of this scope skip the review queue and land live immediately.
New memories of this scope must be human-reviewed before they go live.
Days a memory of this scope is retained before the decay sweep may archive it;
0 keeps it forever. Defaults per scope: shared scopes (workspace/project)
start at [DEFAULT_SHARED_RETENTION_DAYS] (#1228), personal at 0.
not matching
The governance rule for ONE memory scope: whether new memories of that scope skip
the review queue (auto_publish), whether they must be human-reviewed
(require_review), and how long they are retained before the decay sweep may
archive them (retention_days, 0 = keep forever).
auto_publish and require_review are intentionally NOT collapsed into one flag:
the conservative default is “review required, not auto-published”, and a future
“auto-published BUT still logged for review” mode keeps both axes meaningful. The
validation below rejects the contradictory auto_publish && require_review combo.
object
New memories of this scope skip the review queue and land live immediately.
New memories of this scope must be human-reviewed before they go live.
Days a memory of this scope is retained before the decay sweep may archive it;
0 keeps it forever. Defaults per scope: shared scopes (workspace/project)
start at [DEFAULT_SHARED_RETENTION_DAYS] (#1228), personal at 0.
not matching
#1161 D2 — project-level arm fields are rejected with a named422.
These values belong inside a specific automations[] entry; a project-level
pipeline_config cannot identify the arm whose ceilings it governs.
An explicit JSON null is NOT rejected: serde maps null onto None for any
Option<T>, so it is indistinguishable here from an omitted key, exactly as the
closeout_config sibling above documents for itself. That is deliberate rather
than merely accepted — null carries no configuration intent (it cannot express a
cost ceiling), so it is not the failure this trap exists to catch, and IaC
templates that render an unset variable as null keep working. Pinned by
management_project_apply_treats_a_null_arm_field_as_absent.
#1549 item H — bind an installed App’s backend function to an EXISTING
READ-namespace entitlement (the bind-only READ path). Creates no grant and
no namespace; the expected namespace handle and entity must equal what the
server stored for the entitlement, and an already-bound function is never
rebound. Applied after marketplace_installs (the App must exist).
Requires management:credentials:write, the trust class of the grant.
One bind-only READ declaration, by App slug and backend-function name.
object
The App’s stable slug in this workspace.
The backend function of that App to bind.
The EXISTING READ entitlement; it must already authorize this App.
What the caller expects the entitlement to authorize. Checked, never written.
object
The entitlement’s entity (entity isolation), absent for a non-isolated one.
The handle of the namespace the entitlement reads.
Must be read_namespace_script, the only operation that reads a namespace.
The workspace’s own imported Script (by slug) the function runs.
#1214 — the workspace’s git binding. Absent leaves any existing binding
untouched; present upserts it through the same service the browser PUT
calls. Requires management:credentials:write — a repo-only binding
rewrites the whole workspace from the repo, resources and SOPS-imported
secrets included.
object
ADR 0030 UX2-F debounced background push. Absent keeps the stored value,
false on creation.
Defaults to main in the service when empty or absent.
The NAME of a workspace resource holding the git credential — never a
UUID. Resource ids are minted per instance, so a document pinned to one
applies only to the instance it was written against; the document already
names resources this way in its own resources block.
An unknown name is an ERROR, not a silent unbinding: a typo’d credential would otherwise leave a private repo bound and every later pull failing for a reason nothing states.
ADR 0023 §3: bidirectional | repo-only | ui-only. Absent keeps the
stored value on an existing binding, and falls back to bidirectional
(the DB default) when creating one.
Public read/edit/save preserves private connection bytes unless replacement is explicit.
#918 — workspace resources (postgresql / seafile_webdav / telegram_bot / custom / …) with write-only secrets. Additive like every list here: entries absent from the payload are never deleted server-side.
#918 — one workspace resource in the desired state. Mirrors the resource
create/update API surface; the secret is WRITE-ONLY (never echoed back;
the apply result carries a fingerprint at most).
object
Resource kind (closed catalogue + custom, validated by the resources
service). Immutable on update, like the user-facing API.
Resource name — the upsert identity within the workspace (bindings and scripts reference resources by name).
Write-only secret. Absent/null → leave the stored secret alone
(additive contract — IaC can re-apply without re-supplying secrets).
A string is stored as-is; a JSON object (#914 custom structured
secrets) is stored as its canonical JSON serialisation.
object
once | daily | weekly | monthly | interval.
#908 — the step width of an interval cadence in minutes (5–1440).
Required iff cadence = 'interval'; rejected on any other cadence.
Optional task-scope configuration (5-stage MCP allowlist
precedence per ADR-0007). Absent → no scope write. Empty
TaskScopeConfig::default() → wipes all scoping back to “all
enabled MCPs available to every task”.
object
object
object
object
#708 S1 (K-05) — an optional TYPED per-run standard-closeout override, merged into
config.closeout (the exact key the launch path’s resolve_closeout_for_task reads)
by [Self::effective_config], so a M2M-launched task can set its closeout the same way
the web run-start override does. A sparse JSONB bag documented by the
CloseoutConfigPatch schema; null / absent inherits the project/workspace default.
object
Gates the Tier-0 closeout MEMORY proposal. None inherits the next tier.
object
Optional issue-link intent. When BOTH issue_id and issue_url are
present, the launch path links the task to that existing issue by
merging link_issue_id/link_issue_url into config via the typed
services::tasks::IssueLinkConfig builder (ADR 0032, Issue #248). Either
field alone is a no-op, keeping legacy callers that only send config
unchanged.
object
#918 — workflow schedules: one spec creates/updates the schedule row
AND its linked schedule-kind trigger on the workflow.
#918 — one workflow schedule in the desired state: upserts the schedule row
(cadence incl. interval per #908) and ensures the linked schedule-kind
trigger on the workflow exists and is enabled.
object
once | daily | weekly | monthly | interval.
Required iff cadence = 'interval' (5–1440 minutes, #908).
Stable reconcile identity (task_schedules.management_key).
First-fire hint — preserved across re-applies unless the cadence changes (same semantics as managed task schedules).
The workflow’s name (repo-sync slug / display name).
#987 — workflows materialized from a shipped template, upserted per
(project, key) via the workflows.management_key column (migration 337).
The blocks above can only RESOLVE an existing workflow by name; this one
CREATES it, which is what makes a mail / scan workspace provisionable in one
declarative request.
#987 Stage B — one workflow MATERIALIZED FROM A SHIPPED TEMPLATE in the desired state.
Materializes a shipped workflow template per project and stable management key. The key survives workflow renaming and avoids ambiguous name-based reconciliation.
Additive like every list in the document: an entry that disappears from the
payload is never deleted server-side, and a re-apply of an entry whose workflow
already exists is a no-op reporting changed: false (the graph belongs to the
user once it is materialized — the apply never overwrites their edits).
object
The template’s ${{ config.* }} substitution map, plus the per-slug
materialization parameters (e.g. mail_intake’s mailbox_resource_id).
Missing keys fall back to the template’s registry defaults.
A value of the form ${{ resources.<name>.id }} is resolved against the
resources applied EARLIER IN THE SAME REQUEST, so an operator binds a
mailbox or a document library by NAME and never pastes a UUID into a
manifest. An unknown resource name fails the item loudly.
object
Stable reconcile identity within the project (workflows.management_key).
Optional display name for the materialized workflow. Absent → the
template’s own name:. Purely cosmetic: the reconcile identity is key,
so renaming here never orphans the row.
Project that owns the workflow (ManagementProjectSpec.key). Absent → the
workspace’s single project; ambiguous when the workspace has several.
The shipped template slug to materialize (mail_intake, scan_intake,
autodev, …). An unknown slug fails the apply LOUDLY with a 404 rather
than materializing nothing.
#918 — workflow triggers, upserted per (workflow, key) via the
management_key column (migration 325). repo-sync deliberately never
applies triggers: on pull — this is the declarative path.
#918 — one workflow trigger in the desired state, upserted per
(workflow, key) (migration 325 management_key).
object
Stable reconcile identity within the workflow.
Trigger kind (webhook, schedule, telegram, …) — validated by the
triggers service.
Project that owns the workflow (ManagementProjectSpec.key). Absent →
the workflow is looked up across the workspace’s landing project.
The workflow’s name (repo-sync slug / display name).
object
#1546 G1 (mig 679) — the workspace tier of the agent-commit co-author setting:
whether an agent commit carries the launching human’s Co-authored-by line.
Absent leaves it untouched; null inherits the built-in default (ON). Routed
through the same service (and audit row) as the browser settings PATCH.
SC-23 (M2M parity, SCG-047) — the workspace’s SPARSE agent tool-budget override
(workspace_settings.mcp_caps): the rolling-24 h Ops ceiling plus the defaults every
project inherits. Routed through the very set_workspace_mcp_caps service the
browser PUT calls (validation, the plan bound mcp.ops_daily_max and the
workspace_mcp_caps_set audit row live there), so both doors share one write path.
The management owner token acts as the workspace owner. null / absent leaves the
stored override untouched; an unchanged value is an idempotent no-op.
object
Deploy calls one project may make per rolling 24 h (default: no project bucket).
Deploy calls one task may make per Deploy tool (built-in 5).
Ops calls one agent profile may make per rolling hour (instance default 30).
Ops calls one project may make per rolling 24 h (default: the instance workspace-daily default times the autonomy factor).
Ops calls one task may make per Ops tool (built-in 10).
Ops calls one task may make over all Ops tools together (built-in 40).
WORKSPACE ONLY, owner-written: the workspace’s rolling-24 h Ops ceiling
(instance default 100). A raise is bounded by the plan’s mcp.ops_daily_max.
WORKSPACE ONLY: concurrent delegated children one parent task may have in
flight (built-in 10). Replaces the hub-wide SUBTASK_MAX_CHILDREN_PER_PARENT
env var (SCG-146).
AUD-WIR-051 — the durable agent-mailbox retention window in days (1..=3650).
Absent leaves the stored value untouched; null clears it back to the pinned
default. Routed through the same set_message_retention_days service the browser
settings PATCH calls, so the bound lives in one place.
Responses
Section titled “Responses”Workspace desired state applied
object
object
Example generated
{ "changed": true, "results": [ { "changed": true, "fingerprint": "example", "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "key": "example", "resource_type": "example" } ], "workspace_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}