Skip to main content
Each crew carries an autonomy posture that gates every HITL-relevant decision the orchestrator makes — memory writes, skill creation, behavior-monitor escalations, persona suggestions, ephemeral spawns. The dial is read by every subsystem via the shared policy resolver, so a PUT takes effect immediately (the resolver cache is invalidated on write). The CLI counterpart is crewship policy get/list/set. All endpoints require authentication and workspace context. Reads require workspace membership; setting a policy requires MANAGER, ADMIN, or OWNER. Workspace context is supplied as workspace_id query, path context, or X-Workspace-ID and is always checked for membership. Validation rules:
  • full + block is forbidden.
  • reason is required when setting autonomy_level=full.

List Policies

Returns the policy for every (non-deleted) crew in the workspace, ordered by crew name. Used by crewship policy list to render the overview table. Response: 200 OK

Response Fields

Request: no body. Statuses: 200 OK; 400 Bad Request when workspace context is missing; 401 Unauthorized without authentication; 403 Forbidden when the caller is not a workspace member; 500 Internal Server Error for a database failure. The response is always a JSON array, including when empty.

Get Crew Policy

Returns the current policy for one crew. Defaults (guided / warn) are baked into the database, so this is always a single read. Response: 200 OK
set_by_user_id / set_at / reason are omitted on crews whose policy still matches the seed defaults (no operator has ever flipped it). Request: no body. In addition to the statuses above, the route returns 400 when workspace context or the crew path value is missing, 401 without authentication, 403 for a non-member, and 500 for a lookup or resolver failure.

Set Crew Policy

Replaces the policy. Records the audit triple (set_by_user_id, set_at, reason) atomically with the value change and invalidates the resolver cache so the next decision sees the new state. Request Body:
Response: 200 OK — the same shape as GET, reflecting the new state and the freshly-recorded audit triple. The route-level role check returns 403 before the handler for a workspace member below MANAGER; 400 means missing workspace context, 401 means no authenticated user, and 500 means the update failed. The success response is the policy object above, including the newly recorded audit fields. Journal event: policy.changed (workspace audit feed)