# Tasks: Terms & Conditions (Enrollment Experience) (024) **Branch**: `feat/024-terms-and-conditions` **Date**: 2026-01-04 **Input**: [spec.md](./spec.md), [plan.md](./plan.md) ## Phase 1: Setup - [x] T001 Create spec/plan/tasks and checklist. ## Phase 2: Research & Design - [ ] T002 Confirm Graph resource, `@odata.type`, patchable vs read-only fields. - [ ] T003 Confirm assignments endpoints and payload shapes for create/update/delete. - [ ] T004 Decide restore mode (`enabled` vs `preview-only`) and risk classification. ## Phase 3: Tests (TDD) - [ ] T005 Add sync test for `termsAndConditions`. - [ ] T006 Add snapshot capture test (payload + assignments). - [ ] T007 Add restore preview test (restore_mode + action). - [ ] T008 Add restore execution test (sanitization + assignment apply). - [ ] T009 Add normalized display test for key fields. ## Phase 4: Implementation - [ ] T010 Add `termsAndConditions` to `config/tenantpilot.php`. - [ ] T011 Add Graph contract entry in `config/graph_contracts.php` (resource + assignment CRUD paths). - [ ] T012 Ensure `PolicySyncService` imports these policies correctly. - [ ] T013 Ensure `PolicySnapshotService` captures full payload and assignments. - [ ] T014 Ensure `RestoreService` applies create/update and assignments (contract-driven). - [ ] T015 Add `TermsAndConditionsNormalizer` and register it. ## Phase 5: Verification - [ ] T016 Run targeted tests. - [ ] T017 Run Pint (`./vendor/bin/pint --dirty`).