Parent program: #898
Objective
Bind and verify the existing Cloud Tasks validation-order repair without creating a competing implementation. Unauthorized malformed calls to /api/v3/process-video-task must return 403 before request-body validation; authorized malformed calls must retain strict 422 validation; authorized valid calls must preserve existing behavior.
Acceptance criteria
- Authentication gate executes before payload parsing.
- Unauthorized malformed payload is covered and returns
403.
- Authorized malformed payload is covered and returns
422.
- Required exact-head CI, Coverage, CodeQL, Security, Secret Scan, and Dependency Review pass; repository E2E is skipped.
- Exact-head Vercel preview is READY.
- Zero unresolved substantive review threads.
- PR remains draft until the repository truth gate is terminal.
Declared file scope
src/youtube_extension/backend/cloud_api_endpoints.py
tests/unit/test_cloud_routes.py
Focused test paths
tests/unit/test_cloud_routes.py
Canonical implementation
Agent login
groupthinking
Agent run ID
eventrelay-daily-control-20260731-1317z
Claimed timestamp
2026-07-31T13:22:24Z
Latest heartbeat
2026-07-31T13:25:30Z
Current gate state
The implementation predates this focused issue. The rebound truth-gate attempt 30618812433 resolved the issue-number defect but still rejects the missing issue-side agent policy fields. This issue adds those required fields. Any remaining requirement that the intent snapshot predate the PR is a legitimate non-retroactive provenance blocker and must remain fail-closed; it must not be fabricated or bypassed.
No production mutation or merge is authorized by this issue.
Parent program: #898
Objective
Bind and verify the existing Cloud Tasks validation-order repair without creating a competing implementation. Unauthorized malformed calls to
/api/v3/process-video-taskmust return403before request-body validation; authorized malformed calls must retain strict422validation; authorized valid calls must preserve existing behavior.Acceptance criteria
403.422.Declared file scope
src/youtube_extension/backend/cloud_api_endpoints.pytests/unit/test_cloud_routes.pyFocused test paths
tests/unit/test_cloud_routes.pyCanonical implementation
copilot/fix-payload-parameter-issue5746ba2387498b53b347dde630a1efe41323781eAgent login
groupthinkingAgent run ID
eventrelay-daily-control-20260731-1317zClaimed timestamp
2026-07-31T13:22:24ZLatest heartbeat
2026-07-31T13:25:30ZCurrent gate state
The implementation predates this focused issue. The rebound truth-gate attempt 30618812433 resolved the issue-number defect but still rejects the missing issue-side agent policy fields. This issue adds those required fields. Any remaining requirement that the intent snapshot predate the PR is a legitimate non-retroactive provenance blocker and must remain fail-closed; it must not be fabricated or bypassed.
No production mutation or merge is authorized by this issue.