TASK22229: P2-S2 batch 2 migrate portal/representation relay GET endpoints

This commit is contained in:
2026-03-24 07:45:59 +00:00
parent 6edbc431f8
commit fdf95dd0b1
7 changed files with 146 additions and 166 deletions
+35
View File
@@ -801,3 +801,38 @@ Validation:
Follow-ups:
- Continue P2-S2 with Batch 2 as next dedicated commit on this same branch.
---
### CL-021: TASK22229 P2-S2 Batch 2 (my-portal + representation relay GET cluster)
date: 2026-03-24
author: Cline
scope: `pages/api/endpoint/{getmycases_api,getmyrepresentations_api,getwatchedcases_api,getawaitingsubmission_api,getrepresentations_api}.js`, `tests/phase21/endpoint-handler-contract.test.cjs`
type: change
rationale: Deliver second P2-S2 commit by migrating the next bounded portal/representation GET endpoint cluster onto shared `relayGet` while preserving route contracts.
impact: Reduced duplicated relay boilerplate and aligned forwarding behavior with no intended response contract changes.
status: completed
Summary:
- Migrated Batch 2 endpoints to `relayGet`:
- `getmycases_api.js` (preserved title mapping transform)
- `getmyrepresentations_api.js`
- `getwatchedcases_api.js` (preserved watched-case projection transform)
- `getawaitingsubmission_api.js` (preserved title mapping transform)
- `getrepresentations_api.js`
- Updated phase21 endpoint contract tests for migrated handlers by mocking `relayGet` in guard/catch test paths.
Validation:
- `node tests/phase21/api-contract-slice1.test.cjs` -> pass
- helper: 4/4
- file-handler: 53/53
- email-handler: 12/12
- endpoint-handler: 152/152
- documents-handler: 3/3
Follow-ups:
- Continue P2-S2 with Batch 3 as the next dedicated commit on this branch.