Patch Pattern
PATCH /patterns/
V2 fix (API-IMPLEMENTATION-SPEC.md §2 disposition table, I4): allowed fields shrink to — patterns are engine outputs; name/fingerprint/cluster_id are no longer client-patchable (they come from taxonomy config / top-terms / pins, per §6.3/§6.4). Returns the full updated Pattern.
Task LB6: owner_user_id (migration 0069) — the frontend’s pinned owner
concept, distinct from the legacy assignee field above — is also
accepted here (extends this handler rather than a second PATCH route).
A non-null value MUST be a real member of auth.workspace_id (400
non_member otherwise); null unassigns. The change is audit-logged
(pattern.owner_changed, surfaced via GET /patterns//events like the
pin audit trail) and, like every other field this route touches, broadcast
as a real pattern.updated WS frame (app/events.py — see
app/ws/stream.py’s canonical event contract).
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
V2 fix (API-IMPLEMENTATION-SPEC.md §2 disposition table, I4): allowed
fields shrink to {status, assignee, notes} — name/fingerprint/cluster_id
are engine-owned outputs, not client-patchable. assignee maps to the
assignee_id column (migration 0048); notes maps to the existing
resolution_note column (storage name kept, API name renamed).
Task LB6: owner_user_id (migration 0069) is a NEW, separately-tracked
column — the frontend's pinned Pattern.owner_user_id shape — validated in
the router as a real member of the pattern's workspace (400 on a
non-member); null explicitly unassigns. Deliberately not merged with
the legacy, unvalidated assignee/assignee_id pair above.
Response
Successful Response