Task 1c8096f6: Editable assignees on the admin definition edit route #196

2 Commits
Author SHA1 Message Date
overseerandClaude Opus 5.5 2c7ea48ee3 Reject coerced assignee ids
The create and edit quest-definition bodies parsed assignee_child_ids
as lax list[int], so JSON true, 1.0 and "1" were coerced to child id 1
before the core's validator saw them. Use list[StrictInt] on both so
such ids are a 422 and nothing is written.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-23 21:04:50 -04:00
overseerandClaude Opus 5.5 69a434bcdb Accept assignee_child_ids on the admin definition edit route
PATCH /api/v1/admin/quest-definitions/{id} now takes an optional
assignee_child_ids list that replaces the definition's assignee set.
The replace runs inside the core edit's single DAO transaction, so a
rejected list (empty, duplicate, unknown or inactive child) returns 422
and writes nothing, including any other field in the same body. The
existing single regeneration path rebuilds future instances. An omitted
field leaves assignees unchanged.

Task: 1c8096f6-643d-441b-a61a-892e0d5b3b59

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-23 20:57:25 -04:00