> For the complete documentation index, see [llms.txt](https://faction-os.gitbook.io/faction-os-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://faction-os.gitbook.io/faction-os-docs/.spec_system/archive/sessions/phase07-session04-hosted-persistence-and-public-replay-boundaries/tasks.md).

# Task Checklist

**Session ID**: `phase07-session04-hosted-persistence-and-public-replay-boundaries` **Total Tasks**: 25 **Estimated Duration**: 3-4 hours **Created**: 2026-05-30

***

## Legend

* `[x]` = Completed
* `[ ]` = Pending
* `[P]` = Parallelizable (can run with other \[P] tasks)
* `[SNNMM]` = Session reference (NN=phase number, MM=session number)
* `TNNN` = Task ID

***

## Progress Summary

| Category       | Total  | Done   | Remaining |
| -------------- | ------ | ------ | --------- |
| Setup          | 2      | 2      | 0         |
| Foundation     | 8      | 8      | 0         |
| Implementation | 12     | 12     | 0         |
| Testing        | 3      | 3      | 0         |
| **Total**      | **25** | **25** | **0**     |

***

## Setup (2 tasks)

Initial context review and evidence setup.

### Cross-cutting

* [x] T001 \[S0704] Verify Sessions 01-03, routing matrix, hosted payload blocklist, replay/export/archive/scan/backup/War Room redaction docs, and local-only prerequisites before editing source (`.spec_system/PRD/phase_07/phase07_requirement_routing_matrix.md`)
* [x] T002 \[S0704] \[P] Create implementation evidence notes shell for source, docs, test commands, skipped checks, and residual risks (`.spec_system/specs/phase07-session04-hosted-persistence-and-public-replay-boundaries/implementation-notes.md`)

***

## Foundation (8 tasks)

Core persistence and public replay guardrail artifact, shared contracts, and package scaffolding.

### Cross-cutting

* [x] T003 \[S0704] \[P] Create hosted persistence and public replay boundary artifact with data eligibility, server mediation, retention, export, deletion, replay consent, payload caps, takedown, no-index, abuse controls, and Phase 08 erasure handoff sections (`.spec_system/PRD/phase_07/hosted_persistence_public_replay_boundaries.md`)

### packages/protocol

* [x] T004 \[S0704] Create hosted persistence protocol contracts with planned/unavailable state, data eligibility, blocked payload labels, public replay requirement, docs path, unsupported claim, and bounded summary vocabulary (`packages/protocol/src/hostedPersistence.ts`)
* [x] T005 \[S0704] Add protocol tests for hosted persistence vocabulary, storage eligibility decisions, public replay requirements, bounded summary builders, and negative hosted/public claims (`packages/protocol/tests/hostedPersistence.test.ts`)

### apps/server

* [x] T006 \[S0704] Create local hosted persistence diagnostics builder with status-only planned output and no raw token, account id, payload, replay, export, log, backup, request body, or local path fields (`apps/server/src/lib/hostedPersistence.ts`)
* [x] T007 \[S0704] Wire hosted persistence diagnostics route with existing local auth, CORS, rate-limit, compact unavailable errors, and no request-body echo (`apps/server/src/routes/diagnostics.ts`)
* [x] T008 \[S0704] Add server diagnostics route tests for auth inheritance, local-only fallback, planned/unavailable state, and synthetic sensitive payload non-leakage (`apps/server/tests/hostedPersistenceDiagnostics.test.ts`)

### apps/web

* [x] T009 \[S0704] Create browser hosted persistence helper with unavailable storage copy, disabled public replay hosting copy, local URL-fragment replay fallback, replay caps, and no upload/account/storage UI implication (`apps/web/src/lib/hostedPersistence.ts`)
* [x] T010 \[S0704] Add web helper tests for planned/unavailable persistence state, disabled public replay hosting, local replay fragment behavior, and no raw replay/export/account/storage value exposure (`apps/web/tests/hostedPersistence.test.ts`)

***

## Implementation (12 tasks)

Source exports, focused regression coverage, and documentation alignment.

### packages/protocol

* [x] T011 \[S0704] Export hosted persistence contracts from the protocol barrel for server and web consumers (`packages/protocol/src/index.ts`)

### apps/web

* [x] T012 \[S0704] Add replay-link regression assertions that current share links remain redacted local URL fragments, keep payloads bounded, and never imply upload or public replay hosting (`apps/web/tests/replayLink.test.ts`)

### docs

* [x] T013 \[S0704] \[P] Update API docs for `GET /diagnostics/hosted-persistence` as local planned-state diagnostics, not hosted storage or public replay runtime behavior (`docs/api/README_api.md`)
* [x] T014 \[S0704] \[P] Update hosted-service docs with Session 04 storage eligibility, public replay requirements, disabled-default posture, local-only fallback, and Phase 08 erasure handoff (`docs/hosted-services.md`)
* [x] T015 \[S0704] \[P] Update privacy docs with blocked hosted-storage/public-replay payload rules, retention/export/deletion/takedown limits, and no raw-value diagnostic guarantees (`docs/privacy-and-security.md`)
* [x] T016 \[S0704] \[P] Update architecture docs to route hosted persistence and public replay through protocol-first planned-state contracts while preserving local server/browser/Worker separation (`docs/ARCHITECTURE.md`)
* [x] T017 \[S0704] \[P] Update environment docs so reserved Supabase, storage, and public replay placeholders do not imply active hosted persistence or public hosting (`docs/environments.md`)
* [x] T018 \[S0704] \[P] Update deployment docs so deployed Worker health, Cloudflare operations, and public domains are not storage, public replay, retention, deletion, takedown, or erasure proof (`docs/deployment.md`)
* [x] T019 \[S0704] \[P] Update release docs with hosted persistence and public replay guardrails, negative-claim checks, and Phase 08 validation and erasure deferrals (`docs/release.md`)

### Package READMEs

* [x] T020 \[S0704] \[P] Update protocol README to document hosted persistence and public replay contract ownership and future consumer rules (`packages/protocol/README_protocol.md`)
* [x] T021 \[S0704] \[P] Update server README to document hosted persistence diagnostics, unavailable state, local auth inheritance, and redaction boundaries (`apps/server/README_server.md`)
* [x] T022 \[S0704] \[P] Update web README to document browser hosted persistence helper, local replay fragment fallback, disabled public replay hosting, and no account/storage UI (`apps/web/README_web.md`)

***

## Testing (3 tasks)

Verification and quality checks.

### Cross-cutting

* [x] T023 \[S0704] Run focused protocol, server, web, and replay hosted persistence tests and record command evidence and outcomes (`.spec_system/specs/phase07-session04-hosted-persistence-and-public-replay-boundaries/implementation-notes.md`)
* [x] T024 \[S0704] Run focused typechecks or equivalent package checks for changed TypeScript packages and record skipped-check rationale if any (`.spec_system/specs/phase07-session04-hosted-persistence-and-public-replay-boundaries/implementation-notes.md`)
* [x] T025 \[S0704] Validate ASCII encoding, Unix LF line endings, and `git diff --check` for all changed files before handoff (`.spec_system/specs/phase07-session04-hosted-persistence-and-public-replay-boundaries/implementation-notes.md`)

***

## Completion Checklist

Before marking session complete:

* [x] All tasks marked `[x]`
* [x] All tests passing or skipped with explicit rationale
* [x] All files ASCII-encoded
* [x] implementation-notes.md updated
* [x] Ready for the validate workflow step

***

## Next Steps

Run the implement workflow step to begin AI-led implementation.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://faction-os.gitbook.io/faction-os-docs/.spec_system/archive/sessions/phase07-session04-hosted-persistence-and-public-replay-boundaries/tasks.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
