@ttt-productions/ttt-core 0.79.4 → 0.79.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2670,7 +2670,7 @@ export declare const COLLECTION_SCHEMAS: {
2670
2670
  processingAttemptCount: z.ZodOptional<z.ZodNumber>;
2671
2671
  processingLeaseExpiresAt: z.ZodOptional<z.ZodNumber>;
2672
2672
  }, z.core.$strict>], "status">;
2673
- readonly 'pendingMediaArchive/{pendingMediaId}': z.ZodDiscriminatedUnion<[z.ZodObject<{
2673
+ readonly 'pendingMediaArchive/{pendingMediaId}': z.ZodUnion<readonly [z.ZodDiscriminatedUnion<[z.ZodObject<{
2674
2674
  status: z.ZodLiteral<"completed">;
2675
2675
  completedAt: z.ZodNumber;
2676
2676
  terminalAt: z.ZodNumber;
@@ -3463,7 +3463,11 @@ export declare const COLLECTION_SCHEMAS: {
3463
3463
  processingStartedAt: z.ZodOptional<z.ZodNumber>;
3464
3464
  processingAttemptCount: z.ZodOptional<z.ZodNumber>;
3465
3465
  processingLeaseExpiresAt: z.ZodOptional<z.ZodNumber>;
3466
- }, z.core.$strict>], "status">;
3466
+ }, z.core.$strict>], "status">, z.ZodObject<{
3467
+ parseFailed: z.ZodLiteral<true>;
3468
+ archivedAt: z.ZodNumber;
3469
+ raw: z.ZodRecord<z.ZodString, z.ZodUnknown>;
3470
+ }, z.core.$strict>]>;
3467
3471
  readonly 'mediaAssets/{mediaAssetId}': z.ZodObject<{
3468
3472
  mediaAssetId: z.ZodString;
3469
3473
  mediaKind: z.ZodEnum<{
@@ -4330,6 +4334,7 @@ export declare const COLLECTION_SCHEMAS: {
4330
4334
  openHoldCount: z.ZodNumber;
4331
4335
  relatedCaseIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
4332
4336
  contextResolutionPending: z.ZodOptional<z.ZodBoolean>;
4337
+ testListDrill: z.ZodOptional<z.ZodLiteral<true>>;
4333
4338
  createdAt: z.ZodNumber;
4334
4339
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 -23,7 +23,7 @@ import { NotificationDocSchema, NotificationHistoryDocSchema, PendingNotificatio
23
23
  import { NotificationDeliverySchema, NotificationFanoutJobSchema, } from './notification-ledger.js';
24
24
  import { ChatChannelAuthProjectionSchema, ChatScopeDegradedSchema, ChatScopeDegradedCauseSchema, ChatSyncEventSchema, ChatSyncFanoutJobSchema, ChatMessageOutboxSchema, ChatAdminActionCommandSchema, ChatHistoryAnonymizationJobSchema, ChatHistoryAnonymizationAffectedChunkSchema, } from './chat-sync.js';
25
25
  import { SquareAnnouncementJobSchema } from './square-announcement-jobs.js';
26
- import { PendingMediaSchema, ArchivedPendingMediaSchema } from '../media/pending-media.js';
26
+ import { PendingMediaSchema, ArchivedPendingMediaDocSchema } from '../media/pending-media.js';
27
27
  import { MediaAssetSchema } from './media-assets.js';
28
28
  import { MediaActivationJobSchema } from './media-activation-jobs.js';
29
29
  import { ReservedDisplayNameSchema, ReservedRealmNameSchema, StakeShareAuditEventSchema, ShortLinkSchema, FeedbackAliasSchema, UserSuggestionSchema, StatusReconcileQueueEntrySchema, } from './operational.js';
@@ -132,7 +132,7 @@ export const COLLECTION_SCHEMAS = {
132
132
  'pendingAdminDispatches/{adminDispatchId}/conversationFiles/{conversationFileId}': ConversationFileSchema,
133
133
  // ===== Media pipeline =====
134
134
  'pendingMedia/{pendingMediaId}': PendingMediaSchema,
135
- 'pendingMediaArchive/{pendingMediaId}': ArchivedPendingMediaSchema,
135
+ 'pendingMediaArchive/{pendingMediaId}': ArchivedPendingMediaDocSchema,
136
136
  'mediaAssets/{mediaAssetId}': MediaAssetSchema,
137
137
  'mediaActivationJobs/{jobId}': MediaActivationJobSchema,
138
138
  // ===== Notifications =====
@@ -1 +1 @@
1
- {"version":3,"file":"registry.js","sourceRoot":"","sources":["../../src/doc-schemas/registry.ts"],"names":[],"mappings":"AAAA,wFAAwF;AACxF,0FAA0F;AAC1F,oFAAoF;AACpF,yFAAyF;AACzF,mFAAmF;AACnF,EAAE;AACF,0FAA0F;AAC1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E,eAAe;IACxC,2BAA2B,EAAE,mBAAmB;IAChD,+BAA+B,EAAE,uBAAuB;IACxD,mCAAmC,EAAE,2BAA2B;IAChE,qBAAqB,EAAE,mBAAmB;CACK,CAAC;AAIlD;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG;IACtC,2DAA2D,EAAE,KAAK;IAClE,oFAAoF,EAAE,KAAK;IAC3F,2DAA2D,EAAE,KAAK;IAClE,gFAAgF,EAAE,KAAK;IACvF,sEAAsE,EAAE,KAAK;IAC7E,qGAAqG,EAAE,KAAK;IAC5G,wEAAwE,EAAE,oBAAoB;IAC9F,uFAAuF;IACvF,oFAAoF;IACpF,uCAAuC,EAAE,KAAK;IAC9C,uCAAuC,EAAE,KAAK;IAC9C,4CAA4C,EAAE,KAAK;IACnD,0CAA0C,EAAE,IAAI;IAChD,2CAA2C,EAAE,IAAI;IACjD,2CAA2C,EAAE,qBAAqB;IAClE,4DAA4D,EAAE,qBAAqB;IACnF,uCAAuC,EAAE,IAAI;IAC7C,4BAA4B,EAAE,KAAK;CACiC,CAAC;AAEvE;;;;;;;;;;;;;;;GAeG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAsB;IACpD,cAAc;IACd,iBAAiB;IACjB,kBAAkB;IAClB,oFAAoF;IACpF,oEAAoE;IACpE,eAAe;CACP,CAAC","sourcesContent":["// Firestore collection registry — the single, authoritative binding from each Firestore\n// collection/subcollection path template to its document Zod schema. This is the input to\n// the schema-doc generator and the drift-check, and its completeness is CI-enforced\n// (registry.test.ts) against the COLLECTIONS / *_SUBCOLLECTIONS name constants, so a new\n// collection cannot be added without either a schema or an explicit PENDING entry.\n//\n// Path templates reuse the segment names from ../paths/collections.ts (and the shapes the\n// path-builders produce). `{placeholder}` segments are document/parent IDs.\n\nimport type { z } from 'zod';\nimport {\n FullUserSchema,\n UserPrivateDataSchema,\n CraftSkillSchema,\n CraftSkillReferenceSchema,\n} from './user.js';\nimport { PublicUserSchema } from './publicUser.js';\nimport { AccountDeletionRequestV1Schema } from './account-deletion.js';\nimport {\n FullWorkProjectSchema,\n PublicWorkProjectSchema,\n WorkFileFolderSchema,\n WorkFileSchema,\n WorkRealmSchema,\n GuildmateUserSchema,\n PublicGuildmateUserSchema,\n} from './work-project.js';\nimport {\n FullTaleSchema,\n FullChapterSchema,\n FullTuneSchema,\n FullTuneTrackSchema,\n FullTelevisionSchema,\n FullTelevisionEpisodeSchema,\n ThresholdItemSchema,\n PublishedHallItemSchema,\n PublishedChapterSchema,\n PublishedTuneTrackSchema,\n PublishedTelevisionEpisodeSchema,\n HallContentChangeRequestSchema,\n FuturePlansDocumentSchema,\n RulesAndAgreementsSchema,\n LegalPageDocumentSchema,\n TakeItDownPageCopySchema,\n HallLibraryPreferencesSchema,\n} from './content.js';\nimport {\n SquareStreetzPostSchema,\n MentionHistoryDocumentSchema,\n FollowEdgeSchema,\n FollowCounterSchema,\n SquareStreetzLikeSchema,\n TrendingPostsSchema,\n} from './social.js';\nimport {\n PledgePaymentSchema,\n PledgePaymentProviderRefSchema,\n ProcessedStripeEventSchema,\n PledgePaymentLedgerEventSchema,\n PaymentWebhookQuarantineSchema,\n PledgePaymentTotalsDocSchema,\n PledgeRefundRequestSchema,\n} from './payments.js';\nimport {\n FullCommissionListingSchema,\n CommissionProposalSchema,\n AuditionSchema,\n AuditionEntrySchema,\n UserAuditionVoteSchema,\n} from './commissions.js';\nimport {\n GuildChatChannelSchema,\n GuildInviteConversationSchema,\n AdminDispatchSchema,\n ChatMessageV1Schema,\n ConversationFileSchema,\n} from './messaging.js';\nimport { AppConfigSchema, AdminListSchema, ProfanityListSchema, ReservedUsernamesSchema, BlockedFranchiseNamesSchema, AppModeMarkerSchema } from './system.js';\nimport {\n ContentViolationSchema,\n ModerationCascadeManifestSchema,\n ModerationCascadeChangedDocSchema,\n} from './moderation.js';\nimport {\n AdminTaskDocSchema,\n} from './report-docs.js';\nimport { TTTAuditEventSchema } from './audit.js';\nimport {\n NotificationDocSchema,\n NotificationHistoryDocSchema,\n PendingNotificationSchema,\n} from './notifications.js';\nimport {\n NotificationDeliverySchema,\n NotificationFanoutJobSchema,\n} from './notification-ledger.js';\nimport {\n ChatChannelAuthProjectionSchema,\n ChatScopeDegradedSchema,\n ChatScopeDegradedCauseSchema,\n ChatSyncEventSchema,\n ChatSyncFanoutJobSchema,\n ChatMessageOutboxSchema,\n ChatAdminActionCommandSchema,\n ChatHistoryAnonymizationJobSchema,\n ChatHistoryAnonymizationAffectedChunkSchema,\n} from './chat-sync.js';\nimport { SquareAnnouncementJobSchema } from './square-announcement-jobs.js';\nimport { PendingMediaSchema, ArchivedPendingMediaSchema } from '../media/pending-media.js';\nimport { MediaAssetSchema } from './media-assets.js';\nimport { MediaActivationJobSchema } from './media-activation-jobs.js';\nimport {\n ReservedDisplayNameSchema,\n ReservedRealmNameSchema,\n StakeShareAuditEventSchema,\n ShortLinkSchema,\n FeedbackAliasSchema,\n UserSuggestionSchema,\n StatusReconcileQueueEntrySchema,\n} from './operational.js';\n// ===== Trust & Safety — report spine (§A1) =====\nimport {\n ProtectedReportRootV1Schema,\n ReportPublicProjectionV1Schema,\n ReportGroupV1Schema,\n ReportTargetSnapshotV1Schema,\n NarrativeRecordV1Schema,\n} from './safety/report.js';\nimport { SafetyCaseAlertV1Schema } from './safety/case-alert.js';\n// ===== Trust & Safety — child-safety case spine (§A1b, §A2) =====\nimport {\n ChildSafetyCaseListV1Schema,\n ChildSafetyCaseV1Schema,\n ChildSafetySourceSignalV1Schema,\n ChildSafetyDecisionV1Schema,\n ChildSafetyDecisionViewV1Schema,\n ChildSafetyCaseAccountV1Schema,\n ChildSafetyCaseAccountHistoryV1Schema,\n ChildSafetyNcmecSubmissionV1Schema,\n ChildSafetyNcmecSubmissionFileV1Schema,\n ChildSafetyLegalProcessEventV1Schema,\n} from './safety/case.js';\nimport {\n ChildSafetyOwningAliasV1Schema,\n} from './safety/case-aliases.js';\nimport {\n SafetyHoldRefV1Schema,\n SafetyHoldResourceV1Schema,\n SafetyResourceCommandV1Schema,\n SafetyResourceCommandAuthorizedRequestV1Schema,\n SafetyResourceCommandBypassRefV1Schema,\n} from './safety/holds.js';\nimport {\n SafetyEvidenceManifestV1Schema,\n SafetyEvidenceJobV1Schema,\n SafetyEvidenceJobItemV1Schema,\n SafetyEvidenceDispositionV1Schema,\n} from './safety/evidence.js';\nimport { EventProvenanceV1Schema } from './safety/provenance.js';\nimport {\n QuarantineSagaJobV1Schema,\n QuarantineSagaRelatedAssetV1Schema,\n NcmecSubmissionJobV1Schema,\n AccountActionCommandV1Schema,\n} from './safety/sagas.js';\nimport {\n SafetySlaMonitorV1Schema,\n SafetyMonitorHeartbeatV1Schema,\n} from './safety/monitors.js';\nimport { AgeAttestationNonceV1Schema, AgePolicyConfigV1Schema } from './safety/age.js';\nimport {\n PrivilegedReviewerPasskeyProfileV1Schema,\n PrivilegedReviewerCapabilityGrantV1Schema,\n} from './safety/reviewer-security.js';\n// ===== Trust & Safety — NCII / TAKE IT DOWN (§A11) =====\nimport { NciiAllegationV1Schema } from './ncii/allegations.js';\nimport {\n TakeItDownRequestRootV1Schema,\n TakeItDownRequesterPrivateV1Schema,\n TakeItDownSubmissionV1Schema,\n TakeItDownValidityDecisionV1Schema,\n TakeItDownRequestActionV1Schema,\n TakeItDownEvidenceV1Schema,\n NciiRetainedEvidenceInventoryV1Schema,\n} from './ncii/requests.js';\nimport {\n NciiCaseV1Schema,\n NciiCaseAllegationLinkV1Schema,\n NciiCaseRequestLinkV1Schema,\n NciiCaseRemovalActionV1Schema,\n NciiBlockedHashV1Schema,\n} from './ncii/cases.js';\nimport { NciiTemporaryHoldV1Schema } from './ncii/holds.js';\nimport {\n NciiRemovalJobV1Schema,\n NciiRemovalTargetV1Schema,\n} from './ncii/removal.js';\nimport {\n NciiPolicyConfigV1Schema,\n PrivilegedReviewerSecurityProfileV1Schema,\n} from './ncii/config.js';\n\nexport const COLLECTION_SCHEMAS = {\n // ===== Users =====\n 'userProfiles/{userId}': FullUserSchema,\n 'userProfiles/{userId}/privateData/{userId}': UserPrivateDataSchema,\n 'userProfiles/{userId}/privateData/hallLibraryPreferences': HallLibraryPreferencesSchema,\n 'userProfiles/{userId}/profileCraftSkills/{craftSkillId}': CraftSkillSchema,\n 'userProfiles/{userId}/auditionVotes/{auditionId}': UserAuditionVoteSchema,\n 'userProfiles/{userId}/mentionHistory/{docId}': MentionHistoryDocumentSchema,\n 'userProfiles/{userId}/notificationHistory/{notificationId}': NotificationHistoryDocSchema,\n 'userProfiles/{userId}/userLikes/likeHistory/squareStreetzLikes/{postId}': SquareStreetzLikeSchema,\n 'publicUsers/{uid}': PublicUserSchema,\n\n // ===== Work / Realm / Guild =====\n 'allWorkProjects/{workProjectId}': FullWorkProjectSchema,\n 'allWorkProjects/{workProjectId}/guildmateUsers/{uid}': GuildmateUserSchema,\n 'allWorkProjects/{workProjectId}/publicGuildmateUsers/{uid}': PublicGuildmateUserSchema,\n 'allWorkProjects/{workProjectId}/workFileFolders/{workFileFolderId}': WorkFileFolderSchema,\n 'allWorkProjects/{workProjectId}/workFileFolders/{workFileFolderId}/workFiles/{workFileId}': WorkFileSchema,\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}': FullTaleSchema,\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}/taleChapters/{chapterId}': FullChapterSchema,\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}': FullTuneSchema,\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}/tuneTracks/{trackId}': FullTuneTrackSchema,\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}': FullTelevisionSchema,\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}/televisionEpisodes/{episodeId}': FullTelevisionEpisodeSchema,\n 'allWorkProjects/{workProjectId}/guildChatChannels/{guildChatChannelId}': GuildChatChannelSchema,\n // Guild channel + invite messages are REALTIME-ONLY (chat Worker DO) — no Firestore schema.\n 'publicWorkProjects/{workProjectId}': PublicWorkProjectSchema,\n 'workRealms/{workRealmId}': WorkRealmSchema,\n 'guildInviteConversations/{guildInviteId}': GuildInviteConversationSchema,\n // Conversation Files — the flat per-conversation file list. Backend-only writes;\n // client-readable only while the caller holds conversation read access.\n 'guildInviteConversations/{guildInviteId}/conversationFiles/{conversationFileId}': ConversationFileSchema,\n\n // ===== Square / Social =====\n // SquareStreetzPostSchema is a refined ZodObject (superRefine for the MEDIA-101\n // mediaAssetId↔mediaType pair invariant); the schema-doc generator and the\n // drift-check both unwrap the effect to introspect its shape, so binding the\n // refined schema here is correct.\n 'squareStreetzFeed/activePosts/socialPosts/{postId}': SquareStreetzPostSchema,\n 'squareStreetzFeed/trendingPosts': TrendingPostsSchema,\n 'followEdges/{followEdgeId}': FollowEdgeSchema,\n 'followCounters/{followCounterId}': FollowCounterSchema,\n // Durable Square announcement outbox (Admin-SDK-only; deterministic job ids).\n 'squareAnnouncementJobs/{jobId}': SquareAnnouncementJobSchema,\n\n // ===== Payments / pledge ledger =====\n 'pledgePayments/{pledgePaymentId}': PledgePaymentSchema,\n 'pledgePaymentProviderRefs/{pledgePaymentId}': PledgePaymentProviderRefSchema,\n 'processedStripeEvents/{stripeEventId}': ProcessedStripeEventSchema,\n 'pledgePaymentLedgerEvents/{ledgerId}': PledgePaymentLedgerEventSchema,\n 'paymentWebhookQuarantine/{stripeEventId}': PaymentWebhookQuarantineSchema,\n 'pledgePaymentTotals/summary': PledgePaymentTotalsDocSchema,\n 'pledgeRefundRequests/{requestId}': PledgeRefundRequestSchema,\n\n // ===== Threshold / Hall =====\n 'thresholdItems/{thresholdItemId}': ThresholdItemSchema,\n 'hallItems/{hallItemId}': PublishedHallItemSchema,\n // Published hall sub-item projections — the chapter/track/episode docs copied out of\n // the Work at publish time (runPublishApprovedHallLibraryItem). Segment names are the\n // HALL_ITEM_SUBCOLLECTIONS constants (the lowercased WorkProjectType).\n 'hallItems/{hallItemId}/tales/{itemId}': PublishedChapterSchema,\n 'hallItems/{hallItemId}/tunes/{itemId}': PublishedTuneTrackSchema,\n 'hallItems/{hallItemId}/television/{itemId}': PublishedTelevisionEpisodeSchema,\n 'hallContentChangeRequests/{changeRequestId}': HallContentChangeRequestSchema,\n\n // ===== Commission / Audition =====\n 'commissionListings/{commissionListingId}': FullCommissionListingSchema,\n 'commissionListings/{commissionListingId}/commissionProposals/{commissionProposalId}': CommissionProposalSchema,\n 'auditionBoard/{auditionId}': AuditionSchema,\n 'auditionBoard/{auditionId}/auditionEntries/{auditionEntryId}': AuditionEntrySchema,\n\n // ===== Moderation / Reports / Admin =====\n // The report spine (§A1): the restricted root, its public projection subdoc, and the\n // dedup/count group. The root + projection are written by the app's submitReport\n // callable; the group is maintained by an app-side trigger.\n 'contentReports/{reportId}': ProtectedReportRootV1Schema,\n 'contentReports/{reportId}/publicProjection/{reportId}': ReportPublicProjectionV1Schema,\n 'contentReports/{reportId}/private/snapshot': ReportTargetSnapshotV1Schema,\n 'contentReports/{reportId}/private/narrative': NarrativeRecordV1Schema,\n 'activeReportGroups/{groupKey}': ReportGroupV1Schema,\n 'adminTasks/{taskId}': AdminTaskDocSchema,\n 'contentViolations/{violationId}': ContentViolationSchema,\n 'moderationCascadeManifests/{cascadeId}': ModerationCascadeManifestSchema,\n 'moderationCascadeManifests/{cascadeId}/changedDocs/{changedDocId}': ModerationCascadeChangedDocSchema,\n 'auditEvents/{eventId}': TTTAuditEventSchema,\n 'stakeShareAuditEvents/{eventId}': StakeShareAuditEventSchema,\n 'pendingAdminDispatches/{adminDispatchId}': AdminDispatchSchema,\n 'pendingAdminDispatches/{adminDispatchId}/conversationMessages/{adminDispatchMessageId}': ChatMessageV1Schema,\n 'pendingAdminDispatches/{adminDispatchId}/conversationFiles/{conversationFileId}': ConversationFileSchema,\n\n // ===== Media pipeline =====\n 'pendingMedia/{pendingMediaId}': PendingMediaSchema,\n 'pendingMediaArchive/{pendingMediaId}': ArchivedPendingMediaSchema,\n 'mediaAssets/{mediaAssetId}': MediaAssetSchema,\n 'mediaActivationJobs/{jobId}': MediaActivationJobSchema,\n\n // ===== Notifications =====\n 'activeUserNotifications/{notificationId}': NotificationDocSchema,\n 'activeAdminNotifications/{notificationId}': NotificationDocSchema,\n 'adminNotificationHistory/{notificationId}': NotificationHistoryDocSchema,\n 'pendingNotifications/{notificationId}': PendingNotificationSchema,\n\n // ===== Notification redesign — delivery ledger + fanout engine =====\n 'notificationDeliveries/{deliveryId}': NotificationDeliverySchema,\n 'notificationFanoutJobs/{jobId}': NotificationFanoutJobSchema,\n\n // ===== Chat realtime sync / projection / commands =====\n 'chatChannelAuthProjections/{authPairKey}': ChatChannelAuthProjectionSchema,\n 'chatScopeDegraded/{scopeKey}': ChatScopeDegradedSchema,\n 'chatScopeDegraded/{scopeKey}/causes/{causeId}': ChatScopeDegradedCauseSchema,\n 'chatSyncEvents/{eventId}': ChatSyncEventSchema,\n 'chatSyncFanoutJobs/{jobId}': ChatSyncFanoutJobSchema,\n 'chatMessageOutbox/{commandId}': ChatMessageOutboxSchema,\n 'chatAdminActionCommands/{requestId}': ChatAdminActionCommandSchema,\n 'chatHistoryAnonymizationJobs/{jobId}': ChatHistoryAnonymizationJobSchema,\n 'chatHistoryAnonymizationJobs/{jobId}/affectedChunks/{chunkOrdinal}': ChatHistoryAnonymizationAffectedChunkSchema,\n\n // ===== Craft skills index =====\n 'craftSkillsByTag/{tag}/taggedCraftSkills/{compositeId}': CraftSkillReferenceSchema,\n\n // ===== Operational / utility =====\n 'reservedDisplayNames/{displayNameUppercase}': ReservedDisplayNameSchema,\n 'reservedRealmNames/{workingTitleUppercase}': ReservedRealmNameSchema,\n 'accountDeletionRequests/{uid}': AccountDeletionRequestV1Schema,\n 'shortLinks/{shortId}': ShortLinkSchema,\n 'feedbackAliases/{aliasId}': FeedbackAliasSchema,\n 'feedbackSubmissions/{feedbackType}/userSuggestions/{suggestionId}': UserSuggestionSchema,\n 'statusReconcileQueue/{uid}': StatusReconcileQueueEntrySchema,\n\n // ===== Trust & Safety — child-safety case spine (§A1b, §A2) =====\n 'childSafetyCaseList/{caseId}': ChildSafetyCaseListV1Schema,\n 'activeSafetyCaseAlerts/{caseId}': SafetyCaseAlertV1Schema,\n 'childSafetyCases/{caseId}': ChildSafetyCaseV1Schema,\n 'childSafetyCases/{caseId}/sourceSignals/{signalId}': ChildSafetySourceSignalV1Schema,\n 'childSafetyCases/{caseId}/decisions/{decisionId}': ChildSafetyDecisionV1Schema,\n 'childSafetyCases/{caseId}/decisions/{decisionId}/views/{viewId}': ChildSafetyDecisionViewV1Schema,\n 'childSafetyCases/{caseId}/accounts/{uid}': ChildSafetyCaseAccountV1Schema,\n 'childSafetyCases/{caseId}/accounts/{uid}/history/{historyId}': ChildSafetyCaseAccountHistoryV1Schema,\n 'childSafetyCases/{caseId}/ncmecSubmissions/{submissionId}': ChildSafetyNcmecSubmissionV1Schema,\n 'childSafetyCases/{caseId}/ncmecSubmissions/{submissionId}/files/{fileId}': ChildSafetyNcmecSubmissionFileV1Schema,\n 'childSafetyCases/{caseId}/legalProcess/{eventId}': ChildSafetyLegalProcessEventV1Schema,\n 'childSafetyOwningAliases/{aliasId}': ChildSafetyOwningAliasV1Schema,\n\n // ===== Trust & Safety — holds + resource commands (§A3) =====\n 'safetyHoldRefs/{holdRefId}': SafetyHoldRefV1Schema,\n 'safetyHoldResources/{resourceKeyHash}': SafetyHoldResourceV1Schema,\n 'safetyResourceCommands/{commandDocId}': SafetyResourceCommandV1Schema,\n 'safetyResourceCommands/{commandDocId}/authorizedRequests/{requestId}': SafetyResourceCommandAuthorizedRequestV1Schema,\n 'safetyResourceCommands/{commandDocId}/bypassRefs/{refId}': SafetyResourceCommandBypassRefV1Schema,\n\n // ===== Trust & Safety — evidence + provenance (§A4, §A6) =====\n // SafetyEvidenceManifestV1Schema is a refined ZodObject (superRefine for the H5\n // sourceKind invariant); the schema-doc generator unwraps the effect to introspect\n // its shape, so binding the refined schema here is correct.\n 'safetyEvidenceManifests/{manifestId}': SafetyEvidenceManifestV1Schema,\n 'safetyEvidenceJobs/{jobId}': SafetyEvidenceJobV1Schema,\n 'safetyEvidenceJobs/{jobId}/items/{itemId}': SafetyEvidenceJobItemV1Schema,\n 'safetyEvidenceJobs/{jobId}/disposition/{locationId}': SafetyEvidenceDispositionV1Schema,\n 'eventProvenance/{eventId}': EventProvenanceV1Schema,\n\n // ===== Trust & Safety — sagas + closure (§A5) =====\n 'quarantineSagaJobs/{caseId}': QuarantineSagaJobV1Schema,\n 'quarantineSagaJobs/{caseId}/relatedAssets/{assetId}': QuarantineSagaRelatedAssetV1Schema,\n 'ncmecSubmissionJobs/{ncmecJobId}': NcmecSubmissionJobV1Schema,\n 'accountActionCommands/{accountActionCommandId}': AccountActionCommandV1Schema,\n\n // ===== Trust & Safety — SLA monitors + heartbeat (§A8) =====\n 'safetySlaMonitors/{monitorId}': SafetySlaMonitorV1Schema,\n 'safetyMonitorHeartbeat/global': SafetyMonitorHeartbeatV1Schema,\n\n // ===== Trust & Safety — age attestation nonces (§A7) =====\n 'ageAttestationNonces/{nonceHash}': AgeAttestationNonceV1Schema,\n\n // ===== Trust & Safety — per-operator privileged-reviewer security (§A11 [M-6] / [H-17]) =====\n // Backend-only (Cloud-Functions-only readers/writers; client access denied in firestore.rules).\n 'privilegedReviewerPasskeyProfiles/{uid}': PrivilegedReviewerPasskeyProfileV1Schema,\n 'privilegedReviewerCapabilityGrants/{uid}': PrivilegedReviewerCapabilityGrantV1Schema,\n\n // ===== Trust & Safety — NCII / TAKE IT DOWN (§A11) =====\n 'nciiAllegations/{allegationId}': NciiAllegationV1Schema,\n 'takeItDownRequests/{requestId}': TakeItDownRequestRootV1Schema,\n 'takeItDownRequests/{requestId}/private/requester': TakeItDownRequesterPrivateV1Schema,\n 'takeItDownRequests/{requestId}/submissions/{submissionId}': TakeItDownSubmissionV1Schema,\n 'takeItDownRequests/{requestId}/validityDecisions/{decisionId}': TakeItDownValidityDecisionV1Schema,\n 'takeItDownRequests/{requestId}/actions/{actionId}': TakeItDownRequestActionV1Schema,\n 'takeItDownRequests/{requestId}/evidence/{evidenceId}': TakeItDownEvidenceV1Schema,\n 'nciiCases/{caseId}': NciiCaseV1Schema,\n 'nciiCases/{caseId}/allegationLinks/{allegationId}': NciiCaseAllegationLinkV1Schema,\n 'nciiCases/{caseId}/requestLinks/{requestId}': NciiCaseRequestLinkV1Schema,\n 'nciiCases/{caseId}/removalActions/{actionId}': NciiCaseRemovalActionV1Schema,\n 'nciiCases/{caseId}/blockedHashes/{hashId}': NciiBlockedHashV1Schema,\n 'nciiRetainedEvidenceInventory/{inventoryId}': NciiRetainedEvidenceInventoryV1Schema,\n // [H-01] dead-letter sink for inventory rows that could not be written to the primary\n // nciiRetainedEvidenceInventory collection. Stores the same document shape.\n 'nciiInventoryDeadLetter/{inventoryId}': NciiRetainedEvidenceInventoryV1Schema,\n 'nciiTemporaryHolds/{holdId}': NciiTemporaryHoldV1Schema,\n 'nciiRemovalJobs/{jobId}': NciiRemovalJobV1Schema,\n 'nciiRemovalJobs/{jobId}/targets/{targetKeyHash}': NciiRemovalTargetV1Schema,\n\n // ===== _config singletons (public) =====\n '_config/app': AppConfigSchema,\n '_config/futurePlans': FuturePlansDocumentSchema,\n '_config/rulesAndAgreements': RulesAndAgreementsSchema,\n // Content-pages migration (DJ ruling 2026-07-06): /terms, /privacy, and the\n // /take-it-down page copy render exclusively from these (all public pages —\n // take-it-down is a NO-LOGIN page, so its copy doc must be publicly readable).\n '_config/termsOfService': LegalPageDocumentSchema,\n '_config/privacyPolicy': LegalPageDocumentSchema,\n '_config/takeItDownPageCopy': TakeItDownPageCopySchema,\n\n // ===== _serverData singletons (server-only — Cloud-Functions-only readers, BACKEND-108) =====\n '_serverData/agePolicy': AgePolicyConfigV1Schema,\n '_serverData/nciiPolicy': NciiPolicyConfigV1Schema,\n '_serverData/privilegedReviewerSecurity': PrivilegedReviewerSecurityProfileV1Schema,\n\n // ===== _systemData singletons =====\n '_systemData/adminList': AdminListSchema,\n '_systemData/profanityList': ProfanityListSchema,\n '_systemData/reservedUsernames': ReservedUsernamesSchema,\n '_systemData/blockedFranchiseNames': BlockedFranchiseNamesSchema,\n '_systemData/appMode': AppModeMarkerSchema,\n} as const satisfies Record<string, z.ZodTypeAny>;\n\nexport type RegisteredCollectionPath = keyof typeof COLLECTION_SCHEMAS;\n\n/**\n * Doc-id field annotation: for the listed bindings, the named body field equals the\n * Firestore document id and is injected at READ time (`{ ...doc.data(), <field>: doc.id }`),\n * never persisted — the write callables store the body via `Omit<…, '<field>'>`. The bound\n * schema models the (correct) consumer/read shape, where the field is required, so a raw\n * stored doc is \"missing\" it. The drift-check injects `{ [field]: doc.id, ...data }` before\n * validating, generalizing the one-off `AdminTaskDocSchema` stored-shape workaround into a\n * single mechanism so real-callable drift-checks don't false-flag every doc-id collection.\n * The schema-doc generator ignores this map. Keys are compiler-checked against the registry.\n */\nexport const COLLECTION_DOC_ID_FIELDS = {\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}/taleChapters/{chapterId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}/tuneTracks/{trackId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}/televisionEpisodes/{episodeId}': 'uid',\n 'allWorkProjects/{workProjectId}/guildChatChannels/{guildChatChannelId}': 'guildChatChannelId',\n // Published hall sub-items: the doc id IS the live sub-item's id; `uid` is injected at\n // read (the publish writer spreads the live doc's stored body, which has no `uid`).\n 'hallItems/{hallItemId}/tales/{itemId}': 'uid',\n 'hallItems/{hallItemId}/tunes/{itemId}': 'uid',\n 'hallItems/{hallItemId}/television/{itemId}': 'uid',\n 'activeUserNotifications/{notificationId}': 'id',\n 'activeAdminNotifications/{notificationId}': 'id',\n 'adminNotificationHistory/{notificationId}': 'archiveOccurrenceId',\n 'userProfiles/{userId}/notificationHistory/{notificationId}': 'archiveOccurrenceId',\n 'pendingNotifications/{notificationId}': 'id',\n 'statusReconcileQueue/{uid}': 'uid',\n} as const satisfies Partial<Record<RegisteredCollectionPath, string>>;\n\n/**\n * Collections that exist (in COLLECTIONS / *_SUBCOLLECTIONS or firestore.rules) but are\n * intentionally NOT bound to a schema, each with a reason. Listed EXPLICITLY so completeness is\n * enforced and nothing is silently uncovered; the registry test fails if a NEW unlisted collection\n * appears. These three are the only remaining gaps after the schema-registry binding pass:\n *\n * - userMetadata: `userProfiles/{uid}/userMetadata/notificationSettings` — a firestore.rules\n * match and `PATH_BUILDERS.userMetadata` exist, but there is no live reader/writer and no\n * notification-settings type anywhere yet. Bind once that shape is implemented.\n * - checkedOutItems: a `userProfiles/{uid}/checkedOutItems` subcollection constant with no writer,\n * reader, rule, or path-builder (the admin \"checked out items\" UI reads adminTasks by\n * `checkoutDetails.userId`, not this subcollection). Vestigial — remove once confirmed safe.\n * - feedbackDenylist: `feedbackDenylist/{deniedWord}` — Console-managed (firestore.rules §3F: no\n * callable writes it) and submitFeedback reads it via `.exists` only, so there is no field\n * contract to author a schema from. The doc id is the denied word; the body is unused.\n */\nexport const PENDING_COLLECTIONS: readonly string[] = [\n 'userMetadata',\n 'checkedOutItems',\n 'feedbackDenylist',\n // Append-only NCII case closure/reopen event rows — the doc shape is owned app-side\n // (NciiCaseV1 closure events), not modeled in ttt-core doc-schemas.\n 'closureEvents',\n] as const;\n"]}
1
+ {"version":3,"file":"registry.js","sourceRoot":"","sources":["../../src/doc-schemas/registry.ts"],"names":[],"mappings":"AAAA,wFAAwF;AACxF,0FAA0F;AAC1F,oFAAoF;AACpF,yFAAyF;AACzF,mFAAmF;AACnF,EAAE;AACF,0FAA0F;AAC1F,4EAA4E;AAG5E,OAAO,EACL,cAAc,EACd,qBAAqB,EACrB,gBAAgB,EAChB,yBAAyB,GAC1B,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,gBAAgB,EAAE,MA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IlD;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG;IACtC,2DAA2D,EAAE,KAAK;IAClE,oFAAoF,EAAE,KAAK;IAC3F,2DAA2D,EAAE,KAAK;IAClE,gFAAgF,EAAE,KAAK;IACvF,sEAAsE,EAAE,KAAK;IAC7E,qGAAqG,EAAE,KAAK;IAC5G,wEAAwE,EAAE,oBAAoB;IAC9F,uFAAuF;IACvF,oFAAoF;IACpF,uCAAuC,EAAE,KAAK;IAC9C,uCAAuC,EAAE,KAAK;IAC9C,4CAA4C,EAAE,KAAK;IACnD,0CAA0C,EAAE,IAAI;IAChD,2CAA2C,EAAE,IAAI;IACjD,2CAA2C,EAAE,qBAAqB;IAClE,4DAA4D,EAAE,qBAAqB;IACnF,uCAAuC,EAAE,IAAI;IAC7C,4BAA4B,EAAE,KAAK;CACiC,CAAC;AAEvE;;;;;;;;;;;;;;;GAeG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAsB;IACpD,cAAc;IACd,iBAAiB;IACjB,kBAAkB;IAClB,oFAAoF;IACpF,oEAAoE;IACpE,eAAe;CACP,CAAC","sourcesContent":["// Firestore collection registry — the single, authoritative binding from each Firestore\n// collection/subcollection path template to its document Zod schema. This is the input to\n// the schema-doc generator and the drift-check, and its completeness is CI-enforced\n// (registry.test.ts) against the COLLECTIONS / *_SUBCOLLECTIONS name constants, so a new\n// collection cannot be added without either a schema or an explicit PENDING entry.\n//\n// Path templates reuse the segment names from ../paths/collections.ts (and the shapes the\n// path-builders produce). `{placeholder}` segments are document/parent IDs.\n\nimport type { z } from 'zod';\nimport {\n FullUserSchema,\n UserPrivateDataSchema,\n CraftSkillSchema,\n CraftSkillReferenceSchema,\n} from './user.js';\nimport { PublicUserSchema } from './publicUser.js';\nimport { AccountDeletionRequestV1Schema } from './account-deletion.js';\nimport {\n FullWorkProjectSchema,\n PublicWorkProjectSchema,\n WorkFileFolderSchema,\n WorkFileSchema,\n WorkRealmSchema,\n GuildmateUserSchema,\n PublicGuildmateUserSchema,\n} from './work-project.js';\nimport {\n FullTaleSchema,\n FullChapterSchema,\n FullTuneSchema,\n FullTuneTrackSchema,\n FullTelevisionSchema,\n FullTelevisionEpisodeSchema,\n ThresholdItemSchema,\n PublishedHallItemSchema,\n PublishedChapterSchema,\n PublishedTuneTrackSchema,\n PublishedTelevisionEpisodeSchema,\n HallContentChangeRequestSchema,\n FuturePlansDocumentSchema,\n RulesAndAgreementsSchema,\n LegalPageDocumentSchema,\n TakeItDownPageCopySchema,\n HallLibraryPreferencesSchema,\n} from './content.js';\nimport {\n SquareStreetzPostSchema,\n MentionHistoryDocumentSchema,\n FollowEdgeSchema,\n FollowCounterSchema,\n SquareStreetzLikeSchema,\n TrendingPostsSchema,\n} from './social.js';\nimport {\n PledgePaymentSchema,\n PledgePaymentProviderRefSchema,\n ProcessedStripeEventSchema,\n PledgePaymentLedgerEventSchema,\n PaymentWebhookQuarantineSchema,\n PledgePaymentTotalsDocSchema,\n PledgeRefundRequestSchema,\n} from './payments.js';\nimport {\n FullCommissionListingSchema,\n CommissionProposalSchema,\n AuditionSchema,\n AuditionEntrySchema,\n UserAuditionVoteSchema,\n} from './commissions.js';\nimport {\n GuildChatChannelSchema,\n GuildInviteConversationSchema,\n AdminDispatchSchema,\n ChatMessageV1Schema,\n ConversationFileSchema,\n} from './messaging.js';\nimport { AppConfigSchema, AdminListSchema, ProfanityListSchema, ReservedUsernamesSchema, BlockedFranchiseNamesSchema, AppModeMarkerSchema } from './system.js';\nimport {\n ContentViolationSchema,\n ModerationCascadeManifestSchema,\n ModerationCascadeChangedDocSchema,\n} from './moderation.js';\nimport {\n AdminTaskDocSchema,\n} from './report-docs.js';\nimport { TTTAuditEventSchema } from './audit.js';\nimport {\n NotificationDocSchema,\n NotificationHistoryDocSchema,\n PendingNotificationSchema,\n} from './notifications.js';\nimport {\n NotificationDeliverySchema,\n NotificationFanoutJobSchema,\n} from './notification-ledger.js';\nimport {\n ChatChannelAuthProjectionSchema,\n ChatScopeDegradedSchema,\n ChatScopeDegradedCauseSchema,\n ChatSyncEventSchema,\n ChatSyncFanoutJobSchema,\n ChatMessageOutboxSchema,\n ChatAdminActionCommandSchema,\n ChatHistoryAnonymizationJobSchema,\n ChatHistoryAnonymizationAffectedChunkSchema,\n} from './chat-sync.js';\nimport { SquareAnnouncementJobSchema } from './square-announcement-jobs.js';\nimport { PendingMediaSchema, ArchivedPendingMediaDocSchema } from '../media/pending-media.js';\nimport { MediaAssetSchema } from './media-assets.js';\nimport { MediaActivationJobSchema } from './media-activation-jobs.js';\nimport {\n ReservedDisplayNameSchema,\n ReservedRealmNameSchema,\n StakeShareAuditEventSchema,\n ShortLinkSchema,\n FeedbackAliasSchema,\n UserSuggestionSchema,\n StatusReconcileQueueEntrySchema,\n} from './operational.js';\n// ===== Trust & Safety — report spine (§A1) =====\nimport {\n ProtectedReportRootV1Schema,\n ReportPublicProjectionV1Schema,\n ReportGroupV1Schema,\n ReportTargetSnapshotV1Schema,\n NarrativeRecordV1Schema,\n} from './safety/report.js';\nimport { SafetyCaseAlertV1Schema } from './safety/case-alert.js';\n// ===== Trust & Safety — child-safety case spine (§A1b, §A2) =====\nimport {\n ChildSafetyCaseListV1Schema,\n ChildSafetyCaseV1Schema,\n ChildSafetySourceSignalV1Schema,\n ChildSafetyDecisionV1Schema,\n ChildSafetyDecisionViewV1Schema,\n ChildSafetyCaseAccountV1Schema,\n ChildSafetyCaseAccountHistoryV1Schema,\n ChildSafetyNcmecSubmissionV1Schema,\n ChildSafetyNcmecSubmissionFileV1Schema,\n ChildSafetyLegalProcessEventV1Schema,\n} from './safety/case.js';\nimport {\n ChildSafetyOwningAliasV1Schema,\n} from './safety/case-aliases.js';\nimport {\n SafetyHoldRefV1Schema,\n SafetyHoldResourceV1Schema,\n SafetyResourceCommandV1Schema,\n SafetyResourceCommandAuthorizedRequestV1Schema,\n SafetyResourceCommandBypassRefV1Schema,\n} from './safety/holds.js';\nimport {\n SafetyEvidenceManifestV1Schema,\n SafetyEvidenceJobV1Schema,\n SafetyEvidenceJobItemV1Schema,\n SafetyEvidenceDispositionV1Schema,\n} from './safety/evidence.js';\nimport { EventProvenanceV1Schema } from './safety/provenance.js';\nimport {\n QuarantineSagaJobV1Schema,\n QuarantineSagaRelatedAssetV1Schema,\n NcmecSubmissionJobV1Schema,\n AccountActionCommandV1Schema,\n} from './safety/sagas.js';\nimport {\n SafetySlaMonitorV1Schema,\n SafetyMonitorHeartbeatV1Schema,\n} from './safety/monitors.js';\nimport { AgeAttestationNonceV1Schema, AgePolicyConfigV1Schema } from './safety/age.js';\nimport {\n PrivilegedReviewerPasskeyProfileV1Schema,\n PrivilegedReviewerCapabilityGrantV1Schema,\n} from './safety/reviewer-security.js';\n// ===== Trust & Safety — NCII / TAKE IT DOWN (§A11) =====\nimport { NciiAllegationV1Schema } from './ncii/allegations.js';\nimport {\n TakeItDownRequestRootV1Schema,\n TakeItDownRequesterPrivateV1Schema,\n TakeItDownSubmissionV1Schema,\n TakeItDownValidityDecisionV1Schema,\n TakeItDownRequestActionV1Schema,\n TakeItDownEvidenceV1Schema,\n NciiRetainedEvidenceInventoryV1Schema,\n} from './ncii/requests.js';\nimport {\n NciiCaseV1Schema,\n NciiCaseAllegationLinkV1Schema,\n NciiCaseRequestLinkV1Schema,\n NciiCaseRemovalActionV1Schema,\n NciiBlockedHashV1Schema,\n} from './ncii/cases.js';\nimport { NciiTemporaryHoldV1Schema } from './ncii/holds.js';\nimport {\n NciiRemovalJobV1Schema,\n NciiRemovalTargetV1Schema,\n} from './ncii/removal.js';\nimport {\n NciiPolicyConfigV1Schema,\n PrivilegedReviewerSecurityProfileV1Schema,\n} from './ncii/config.js';\n\nexport const COLLECTION_SCHEMAS = {\n // ===== Users =====\n 'userProfiles/{userId}': FullUserSchema,\n 'userProfiles/{userId}/privateData/{userId}': UserPrivateDataSchema,\n 'userProfiles/{userId}/privateData/hallLibraryPreferences': HallLibraryPreferencesSchema,\n 'userProfiles/{userId}/profileCraftSkills/{craftSkillId}': CraftSkillSchema,\n 'userProfiles/{userId}/auditionVotes/{auditionId}': UserAuditionVoteSchema,\n 'userProfiles/{userId}/mentionHistory/{docId}': MentionHistoryDocumentSchema,\n 'userProfiles/{userId}/notificationHistory/{notificationId}': NotificationHistoryDocSchema,\n 'userProfiles/{userId}/userLikes/likeHistory/squareStreetzLikes/{postId}': SquareStreetzLikeSchema,\n 'publicUsers/{uid}': PublicUserSchema,\n\n // ===== Work / Realm / Guild =====\n 'allWorkProjects/{workProjectId}': FullWorkProjectSchema,\n 'allWorkProjects/{workProjectId}/guildmateUsers/{uid}': GuildmateUserSchema,\n 'allWorkProjects/{workProjectId}/publicGuildmateUsers/{uid}': PublicGuildmateUserSchema,\n 'allWorkProjects/{workProjectId}/workFileFolders/{workFileFolderId}': WorkFileFolderSchema,\n 'allWorkProjects/{workProjectId}/workFileFolders/{workFileFolderId}/workFiles/{workFileId}': WorkFileSchema,\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}': FullTaleSchema,\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}/taleChapters/{chapterId}': FullChapterSchema,\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}': FullTuneSchema,\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}/tuneTracks/{trackId}': FullTuneTrackSchema,\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}': FullTelevisionSchema,\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}/televisionEpisodes/{episodeId}': FullTelevisionEpisodeSchema,\n 'allWorkProjects/{workProjectId}/guildChatChannels/{guildChatChannelId}': GuildChatChannelSchema,\n // Guild channel + invite messages are REALTIME-ONLY (chat Worker DO) — no Firestore schema.\n 'publicWorkProjects/{workProjectId}': PublicWorkProjectSchema,\n 'workRealms/{workRealmId}': WorkRealmSchema,\n 'guildInviteConversations/{guildInviteId}': GuildInviteConversationSchema,\n // Conversation Files — the flat per-conversation file list. Backend-only writes;\n // client-readable only while the caller holds conversation read access.\n 'guildInviteConversations/{guildInviteId}/conversationFiles/{conversationFileId}': ConversationFileSchema,\n\n // ===== Square / Social =====\n // SquareStreetzPostSchema is a refined ZodObject (superRefine for the MEDIA-101\n // mediaAssetId↔mediaType pair invariant); the schema-doc generator and the\n // drift-check both unwrap the effect to introspect its shape, so binding the\n // refined schema here is correct.\n 'squareStreetzFeed/activePosts/socialPosts/{postId}': SquareStreetzPostSchema,\n 'squareStreetzFeed/trendingPosts': TrendingPostsSchema,\n 'followEdges/{followEdgeId}': FollowEdgeSchema,\n 'followCounters/{followCounterId}': FollowCounterSchema,\n // Durable Square announcement outbox (Admin-SDK-only; deterministic job ids).\n 'squareAnnouncementJobs/{jobId}': SquareAnnouncementJobSchema,\n\n // ===== Payments / pledge ledger =====\n 'pledgePayments/{pledgePaymentId}': PledgePaymentSchema,\n 'pledgePaymentProviderRefs/{pledgePaymentId}': PledgePaymentProviderRefSchema,\n 'processedStripeEvents/{stripeEventId}': ProcessedStripeEventSchema,\n 'pledgePaymentLedgerEvents/{ledgerId}': PledgePaymentLedgerEventSchema,\n 'paymentWebhookQuarantine/{stripeEventId}': PaymentWebhookQuarantineSchema,\n 'pledgePaymentTotals/summary': PledgePaymentTotalsDocSchema,\n 'pledgeRefundRequests/{requestId}': PledgeRefundRequestSchema,\n\n // ===== Threshold / Hall =====\n 'thresholdItems/{thresholdItemId}': ThresholdItemSchema,\n 'hallItems/{hallItemId}': PublishedHallItemSchema,\n // Published hall sub-item projections — the chapter/track/episode docs copied out of\n // the Work at publish time (runPublishApprovedHallLibraryItem). Segment names are the\n // HALL_ITEM_SUBCOLLECTIONS constants (the lowercased WorkProjectType).\n 'hallItems/{hallItemId}/tales/{itemId}': PublishedChapterSchema,\n 'hallItems/{hallItemId}/tunes/{itemId}': PublishedTuneTrackSchema,\n 'hallItems/{hallItemId}/television/{itemId}': PublishedTelevisionEpisodeSchema,\n 'hallContentChangeRequests/{changeRequestId}': HallContentChangeRequestSchema,\n\n // ===== Commission / Audition =====\n 'commissionListings/{commissionListingId}': FullCommissionListingSchema,\n 'commissionListings/{commissionListingId}/commissionProposals/{commissionProposalId}': CommissionProposalSchema,\n 'auditionBoard/{auditionId}': AuditionSchema,\n 'auditionBoard/{auditionId}/auditionEntries/{auditionEntryId}': AuditionEntrySchema,\n\n // ===== Moderation / Reports / Admin =====\n // The report spine (§A1): the restricted root, its public projection subdoc, and the\n // dedup/count group. The root + projection are written by the app's submitReport\n // callable; the group is maintained by an app-side trigger.\n 'contentReports/{reportId}': ProtectedReportRootV1Schema,\n 'contentReports/{reportId}/publicProjection/{reportId}': ReportPublicProjectionV1Schema,\n 'contentReports/{reportId}/private/snapshot': ReportTargetSnapshotV1Schema,\n 'contentReports/{reportId}/private/narrative': NarrativeRecordV1Schema,\n 'activeReportGroups/{groupKey}': ReportGroupV1Schema,\n 'adminTasks/{taskId}': AdminTaskDocSchema,\n 'contentViolations/{violationId}': ContentViolationSchema,\n 'moderationCascadeManifests/{cascadeId}': ModerationCascadeManifestSchema,\n 'moderationCascadeManifests/{cascadeId}/changedDocs/{changedDocId}': ModerationCascadeChangedDocSchema,\n 'auditEvents/{eventId}': TTTAuditEventSchema,\n 'stakeShareAuditEvents/{eventId}': StakeShareAuditEventSchema,\n 'pendingAdminDispatches/{adminDispatchId}': AdminDispatchSchema,\n 'pendingAdminDispatches/{adminDispatchId}/conversationMessages/{adminDispatchMessageId}': ChatMessageV1Schema,\n 'pendingAdminDispatches/{adminDispatchId}/conversationFiles/{conversationFileId}': ConversationFileSchema,\n\n // ===== Media pipeline =====\n 'pendingMedia/{pendingMediaId}': PendingMediaSchema,\n 'pendingMediaArchive/{pendingMediaId}': ArchivedPendingMediaDocSchema,\n 'mediaAssets/{mediaAssetId}': MediaAssetSchema,\n 'mediaActivationJobs/{jobId}': MediaActivationJobSchema,\n\n // ===== Notifications =====\n 'activeUserNotifications/{notificationId}': NotificationDocSchema,\n 'activeAdminNotifications/{notificationId}': NotificationDocSchema,\n 'adminNotificationHistory/{notificationId}': NotificationHistoryDocSchema,\n 'pendingNotifications/{notificationId}': PendingNotificationSchema,\n\n // ===== Notification redesign — delivery ledger + fanout engine =====\n 'notificationDeliveries/{deliveryId}': NotificationDeliverySchema,\n 'notificationFanoutJobs/{jobId}': NotificationFanoutJobSchema,\n\n // ===== Chat realtime sync / projection / commands =====\n 'chatChannelAuthProjections/{authPairKey}': ChatChannelAuthProjectionSchema,\n 'chatScopeDegraded/{scopeKey}': ChatScopeDegradedSchema,\n 'chatScopeDegraded/{scopeKey}/causes/{causeId}': ChatScopeDegradedCauseSchema,\n 'chatSyncEvents/{eventId}': ChatSyncEventSchema,\n 'chatSyncFanoutJobs/{jobId}': ChatSyncFanoutJobSchema,\n 'chatMessageOutbox/{commandId}': ChatMessageOutboxSchema,\n 'chatAdminActionCommands/{requestId}': ChatAdminActionCommandSchema,\n 'chatHistoryAnonymizationJobs/{jobId}': ChatHistoryAnonymizationJobSchema,\n 'chatHistoryAnonymizationJobs/{jobId}/affectedChunks/{chunkOrdinal}': ChatHistoryAnonymizationAffectedChunkSchema,\n\n // ===== Craft skills index =====\n 'craftSkillsByTag/{tag}/taggedCraftSkills/{compositeId}': CraftSkillReferenceSchema,\n\n // ===== Operational / utility =====\n 'reservedDisplayNames/{displayNameUppercase}': ReservedDisplayNameSchema,\n 'reservedRealmNames/{workingTitleUppercase}': ReservedRealmNameSchema,\n 'accountDeletionRequests/{uid}': AccountDeletionRequestV1Schema,\n 'shortLinks/{shortId}': ShortLinkSchema,\n 'feedbackAliases/{aliasId}': FeedbackAliasSchema,\n 'feedbackSubmissions/{feedbackType}/userSuggestions/{suggestionId}': UserSuggestionSchema,\n 'statusReconcileQueue/{uid}': StatusReconcileQueueEntrySchema,\n\n // ===== Trust & Safety — child-safety case spine (§A1b, §A2) =====\n 'childSafetyCaseList/{caseId}': ChildSafetyCaseListV1Schema,\n 'activeSafetyCaseAlerts/{caseId}': SafetyCaseAlertV1Schema,\n 'childSafetyCases/{caseId}': ChildSafetyCaseV1Schema,\n 'childSafetyCases/{caseId}/sourceSignals/{signalId}': ChildSafetySourceSignalV1Schema,\n 'childSafetyCases/{caseId}/decisions/{decisionId}': ChildSafetyDecisionV1Schema,\n 'childSafetyCases/{caseId}/decisions/{decisionId}/views/{viewId}': ChildSafetyDecisionViewV1Schema,\n 'childSafetyCases/{caseId}/accounts/{uid}': ChildSafetyCaseAccountV1Schema,\n 'childSafetyCases/{caseId}/accounts/{uid}/history/{historyId}': ChildSafetyCaseAccountHistoryV1Schema,\n 'childSafetyCases/{caseId}/ncmecSubmissions/{submissionId}': ChildSafetyNcmecSubmissionV1Schema,\n 'childSafetyCases/{caseId}/ncmecSubmissions/{submissionId}/files/{fileId}': ChildSafetyNcmecSubmissionFileV1Schema,\n 'childSafetyCases/{caseId}/legalProcess/{eventId}': ChildSafetyLegalProcessEventV1Schema,\n 'childSafetyOwningAliases/{aliasId}': ChildSafetyOwningAliasV1Schema,\n\n // ===== Trust & Safety — holds + resource commands (§A3) =====\n 'safetyHoldRefs/{holdRefId}': SafetyHoldRefV1Schema,\n 'safetyHoldResources/{resourceKeyHash}': SafetyHoldResourceV1Schema,\n 'safetyResourceCommands/{commandDocId}': SafetyResourceCommandV1Schema,\n 'safetyResourceCommands/{commandDocId}/authorizedRequests/{requestId}': SafetyResourceCommandAuthorizedRequestV1Schema,\n 'safetyResourceCommands/{commandDocId}/bypassRefs/{refId}': SafetyResourceCommandBypassRefV1Schema,\n\n // ===== Trust & Safety — evidence + provenance (§A4, §A6) =====\n // SafetyEvidenceManifestV1Schema is a refined ZodObject (superRefine for the H5\n // sourceKind invariant); the schema-doc generator unwraps the effect to introspect\n // its shape, so binding the refined schema here is correct.\n 'safetyEvidenceManifests/{manifestId}': SafetyEvidenceManifestV1Schema,\n 'safetyEvidenceJobs/{jobId}': SafetyEvidenceJobV1Schema,\n 'safetyEvidenceJobs/{jobId}/items/{itemId}': SafetyEvidenceJobItemV1Schema,\n 'safetyEvidenceJobs/{jobId}/disposition/{locationId}': SafetyEvidenceDispositionV1Schema,\n 'eventProvenance/{eventId}': EventProvenanceV1Schema,\n\n // ===== Trust & Safety — sagas + closure (§A5) =====\n 'quarantineSagaJobs/{caseId}': QuarantineSagaJobV1Schema,\n 'quarantineSagaJobs/{caseId}/relatedAssets/{assetId}': QuarantineSagaRelatedAssetV1Schema,\n 'ncmecSubmissionJobs/{ncmecJobId}': NcmecSubmissionJobV1Schema,\n 'accountActionCommands/{accountActionCommandId}': AccountActionCommandV1Schema,\n\n // ===== Trust & Safety — SLA monitors + heartbeat (§A8) =====\n 'safetySlaMonitors/{monitorId}': SafetySlaMonitorV1Schema,\n 'safetyMonitorHeartbeat/global': SafetyMonitorHeartbeatV1Schema,\n\n // ===== Trust & Safety — age attestation nonces (§A7) =====\n 'ageAttestationNonces/{nonceHash}': AgeAttestationNonceV1Schema,\n\n // ===== Trust & Safety — per-operator privileged-reviewer security (§A11 [M-6] / [H-17]) =====\n // Backend-only (Cloud-Functions-only readers/writers; client access denied in firestore.rules).\n 'privilegedReviewerPasskeyProfiles/{uid}': PrivilegedReviewerPasskeyProfileV1Schema,\n 'privilegedReviewerCapabilityGrants/{uid}': PrivilegedReviewerCapabilityGrantV1Schema,\n\n // ===== Trust & Safety — NCII / TAKE IT DOWN (§A11) =====\n 'nciiAllegations/{allegationId}': NciiAllegationV1Schema,\n 'takeItDownRequests/{requestId}': TakeItDownRequestRootV1Schema,\n 'takeItDownRequests/{requestId}/private/requester': TakeItDownRequesterPrivateV1Schema,\n 'takeItDownRequests/{requestId}/submissions/{submissionId}': TakeItDownSubmissionV1Schema,\n 'takeItDownRequests/{requestId}/validityDecisions/{decisionId}': TakeItDownValidityDecisionV1Schema,\n 'takeItDownRequests/{requestId}/actions/{actionId}': TakeItDownRequestActionV1Schema,\n 'takeItDownRequests/{requestId}/evidence/{evidenceId}': TakeItDownEvidenceV1Schema,\n 'nciiCases/{caseId}': NciiCaseV1Schema,\n 'nciiCases/{caseId}/allegationLinks/{allegationId}': NciiCaseAllegationLinkV1Schema,\n 'nciiCases/{caseId}/requestLinks/{requestId}': NciiCaseRequestLinkV1Schema,\n 'nciiCases/{caseId}/removalActions/{actionId}': NciiCaseRemovalActionV1Schema,\n 'nciiCases/{caseId}/blockedHashes/{hashId}': NciiBlockedHashV1Schema,\n 'nciiRetainedEvidenceInventory/{inventoryId}': NciiRetainedEvidenceInventoryV1Schema,\n // [H-01] dead-letter sink for inventory rows that could not be written to the primary\n // nciiRetainedEvidenceInventory collection. Stores the same document shape.\n 'nciiInventoryDeadLetter/{inventoryId}': NciiRetainedEvidenceInventoryV1Schema,\n 'nciiTemporaryHolds/{holdId}': NciiTemporaryHoldV1Schema,\n 'nciiRemovalJobs/{jobId}': NciiRemovalJobV1Schema,\n 'nciiRemovalJobs/{jobId}/targets/{targetKeyHash}': NciiRemovalTargetV1Schema,\n\n // ===== _config singletons (public) =====\n '_config/app': AppConfigSchema,\n '_config/futurePlans': FuturePlansDocumentSchema,\n '_config/rulesAndAgreements': RulesAndAgreementsSchema,\n // Content-pages migration (DJ ruling 2026-07-06): /terms, /privacy, and the\n // /take-it-down page copy render exclusively from these (all public pages —\n // take-it-down is a NO-LOGIN page, so its copy doc must be publicly readable).\n '_config/termsOfService': LegalPageDocumentSchema,\n '_config/privacyPolicy': LegalPageDocumentSchema,\n '_config/takeItDownPageCopy': TakeItDownPageCopySchema,\n\n // ===== _serverData singletons (server-only — Cloud-Functions-only readers, BACKEND-108) =====\n '_serverData/agePolicy': AgePolicyConfigV1Schema,\n '_serverData/nciiPolicy': NciiPolicyConfigV1Schema,\n '_serverData/privilegedReviewerSecurity': PrivilegedReviewerSecurityProfileV1Schema,\n\n // ===== _systemData singletons =====\n '_systemData/adminList': AdminListSchema,\n '_systemData/profanityList': ProfanityListSchema,\n '_systemData/reservedUsernames': ReservedUsernamesSchema,\n '_systemData/blockedFranchiseNames': BlockedFranchiseNamesSchema,\n '_systemData/appMode': AppModeMarkerSchema,\n} as const satisfies Record<string, z.ZodTypeAny>;\n\nexport type RegisteredCollectionPath = keyof typeof COLLECTION_SCHEMAS;\n\n/**\n * Doc-id field annotation: for the listed bindings, the named body field equals the\n * Firestore document id and is injected at READ time (`{ ...doc.data(), <field>: doc.id }`),\n * never persisted — the write callables store the body via `Omit<…, '<field>'>`. The bound\n * schema models the (correct) consumer/read shape, where the field is required, so a raw\n * stored doc is \"missing\" it. The drift-check injects `{ [field]: doc.id, ...data }` before\n * validating, generalizing the one-off `AdminTaskDocSchema` stored-shape workaround into a\n * single mechanism so real-callable drift-checks don't false-flag every doc-id collection.\n * The schema-doc generator ignores this map. Keys are compiler-checked against the registry.\n */\nexport const COLLECTION_DOC_ID_FIELDS = {\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTales/{taleId}/taleChapters/{chapterId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTunes/{tuneId}/tuneTracks/{trackId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}': 'uid',\n 'allWorkProjects/{workProjectId}/workProjectTelevision/{televisionId}/televisionEpisodes/{episodeId}': 'uid',\n 'allWorkProjects/{workProjectId}/guildChatChannels/{guildChatChannelId}': 'guildChatChannelId',\n // Published hall sub-items: the doc id IS the live sub-item's id; `uid` is injected at\n // read (the publish writer spreads the live doc's stored body, which has no `uid`).\n 'hallItems/{hallItemId}/tales/{itemId}': 'uid',\n 'hallItems/{hallItemId}/tunes/{itemId}': 'uid',\n 'hallItems/{hallItemId}/television/{itemId}': 'uid',\n 'activeUserNotifications/{notificationId}': 'id',\n 'activeAdminNotifications/{notificationId}': 'id',\n 'adminNotificationHistory/{notificationId}': 'archiveOccurrenceId',\n 'userProfiles/{userId}/notificationHistory/{notificationId}': 'archiveOccurrenceId',\n 'pendingNotifications/{notificationId}': 'id',\n 'statusReconcileQueue/{uid}': 'uid',\n} as const satisfies Partial<Record<RegisteredCollectionPath, string>>;\n\n/**\n * Collections that exist (in COLLECTIONS / *_SUBCOLLECTIONS or firestore.rules) but are\n * intentionally NOT bound to a schema, each with a reason. Listed EXPLICITLY so completeness is\n * enforced and nothing is silently uncovered; the registry test fails if a NEW unlisted collection\n * appears. These three are the only remaining gaps after the schema-registry binding pass:\n *\n * - userMetadata: `userProfiles/{uid}/userMetadata/notificationSettings` — a firestore.rules\n * match and `PATH_BUILDERS.userMetadata` exist, but there is no live reader/writer and no\n * notification-settings type anywhere yet. Bind once that shape is implemented.\n * - checkedOutItems: a `userProfiles/{uid}/checkedOutItems` subcollection constant with no writer,\n * reader, rule, or path-builder (the admin \"checked out items\" UI reads adminTasks by\n * `checkoutDetails.userId`, not this subcollection). Vestigial — remove once confirmed safe.\n * - feedbackDenylist: `feedbackDenylist/{deniedWord}` — Console-managed (firestore.rules §3F: no\n * callable writes it) and submitFeedback reads it via `.exists` only, so there is no field\n * contract to author a schema from. The doc id is the denied word; the body is unused.\n */\nexport const PENDING_COLLECTIONS: readonly string[] = [\n 'userMetadata',\n 'checkedOutItems',\n 'feedbackDenylist',\n // Append-only NCII case closure/reopen event rows — the doc shape is owned app-side\n // (NciiCaseV1 closure events), not modeled in ttt-core doc-schemas.\n 'closureEvents',\n] as const;\n"]}
@@ -224,6 +224,7 @@ export declare const ChildSafetyCaseListV1Schema: z.ZodObject<{
224
224
  openHoldCount: z.ZodNumber;
225
225
  relatedCaseIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
226
226
  contextResolutionPending: z.ZodOptional<z.ZodBoolean>;
227
+ testListDrill: z.ZodOptional<z.ZodLiteral<true>>;
227
228
  createdAt: z.ZodNumber;
228
229
  updatedAt: z.ZodNumber;
229
230
  }, z.core.$strict>;
@@ -1 +1 @@
1
- {"version":3,"file":"case.d.ts","sourceRoot":"","sources":["../../../src/doc-schemas/safety/case.ts"],"names":[],"mappings":"AAuBA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmBxB,kDAAkD;AA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BAID,CAAC;AACpD,MAAM,MAAM,iCAAiC,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uCAAuC,CAAC,CAAC"}
@@ -192,6 +192,16 @@ export const ChildSafetyCaseListV1Schema = z.object({
192
192
  // context). Cleared once context is attached. Surfaced in the safety console so the reviewer
193
193
  // knows to trigger a manual re-fetch if the async retry hasn't landed yet.
194
194
  contextResolutionPending: z.boolean().optional(),
195
+ // Test-list drill lane (DJ ruling 2026-07-28): true ⇔ every validated PhotoDNA match on this
196
+ // case matched ONLY Microsoft's published TEST hash list (the detector echoes listId "Test"),
197
+ // never a production list. A drill case is reviewable and closeable through the normal guided
198
+ // flow but carries NO reporting obligation: the converge path sets no actualKnowledgeAt, no
199
+ // reportRequired, enqueues no NCMEC submission, and arms no report-clock monitors — and the
200
+ // `notRequired` disposition invariant exempts it (a test-image match is definitionally not
201
+ // CSAM; auto-filing a CyberTipline report over it would be wrong). CLEARED (deleted) the
202
+ // moment a real-list match joins the case — real evidence instantly restores the full
203
+ // obligation machinery. Absent = real case.
204
+ testListDrill: z.literal(true).optional(),
195
205
  createdAt: z.number(),
196
206
  updatedAt: z.number(),
197
207
  }).strict();
@@ -1 +1 @@
1
- {"version":3,"file":"case.js","sourceRoot":"","sources":["../../../src/doc-schemas/safety/case.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,EAAE;AACF,gEAAgE;AAChE,4EAA4E;AAC5E,6EAA6E;AAC7E,+EAA+E;AAC/E,oEAAoE;AACpE,yDAAyD;AACzD,EAAE;AACF,+EAA+E;AAC/E,8EAA8E;AAC9E,qDAAqD;AACrD,8CAA8C;AAC9C,EAAE;AACF,sEAAsE;AACtE,2EAA2E;AAC3E,kEAAkE;AAClE,8CAA8C;AAC9C,EAAE;AACF,8EAA8E;AAC9E,4EAA4E;AAC5E,wEAAwE;AAExE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,uBAAuB,EACvB,iCAAiC,EACjC,iCAAiC,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F,sGAAsG;AACtG,iGAAiG;AACjG,sGAAsG;AACtG,MAAM,CAAC,MAAM,uCAAuC,GAAG,uCAAuC,CAAC,MAAM,CAAC;IACpG,YAAY,EAAE,CAAC,CAAC,OAAO,CAAC,wCAAwC,CAAC;CAClE,CAAC;KACC,WAAW,CAAC,iCAAiC,CAAC;KAC9C,WAAW,CAAC,mCAAmC,CAAC,CAAC","sourcesContent":["// Trust & Safety — the child-safety CASE spine (Appendix A §A1b, §A9).\n//\n// The split-projection case model: a reviewer list/metadata doc\n// (`childSafetyCaseList/{caseId}` — NO content, NO reporter identity) and a\n// restricted root (`childSafetyCases/{caseId}` — adds the evidence manifest,\n// the internal reason, and the lease/fencing fields). Append-only detail lives\n// in subcollections (NEVER arrays), each enforced by writing to the\n// subcollection so there is no parent array to overflow.\n//\n// Every shape here is transcribed verbatim from the frozen Trust & Safety spec\n// (Appendix A §A1b + the §A9 state-transition rules) — no invented values, no\n// placeholders; the durable design owner is ttt-prod\n// docs/design/csam-detection-and-response.md.\n//\n// SHARED enums come from ./foundation.js (the single source for every\n// cross-cluster enum); they are NEVER redefined here. This cluster IMPORTS\n// ReportDispositionSchema, ReportDispositionReasonCodeSchema, and\n// NcmecSubmissionStateSchema from foundation.\n//\n// Collection note: this cluster introduces NEW Firestore collections; the app\n// leg (orchestrator) wires collections.ts / path-builders.ts / registry.ts.\n// The merge/alias/correlation cluster (§A2) lives in ./case-aliases.js.\n\nimport { z } from 'zod';\nimport {\n ReportDispositionSchema,\n ReportDispositionReasonCodeSchema,\n refineReportDispositionReasonCode,\n refineReportDispositionEvidenceRefs,\n NcmecSubmissionStateSchema,\n SafetyCaseClosureV1Schema,\n TargetLocatorV1Schema,\n SafetyCrossoverLegStatusSchema,\n} from './foundation.js';\nimport { MAX_MANIFEST_NCMEC_RECEIPTS } from './evidence.js';\nimport { LEGAL_REPORTING_DISPOSITION_CONFIRMATION } from '../../constants/safety-confirmation-phrases.js';\n\n// ===========================================================================\n// Cluster-local enums (§A1b + §A9). These are case-spine-specific value sets,\n// NOT cross-cluster; they live here, not in foundation.\n// ===========================================================================\n\n/** Incident classification on the case (§A1b). */\nexport const ChildSafetyIncidentClassSchema = z.enum([\n 'apparentCsam',\n 'enticement',\n 'minorSexTrafficking',\n 'sextortion',\n 'csamSolicitation',\n 'imminentCsea',\n 'nonReportableSafety',\n]);\nexport type ChildSafetyIncidentClass = z.infer<typeof ChildSafetyIncidentClassSchema>;\n\n/** Source-signal kind (shared by the case `sourceSignalSummary` projection and\n * the `…/sourceSignals/{signalId}` append-only rows). */\nexport const ChildSafetySignalKindSchema = z.enum([\n 'hashMatch',\n 'report',\n 'aiFlag',\n 'manual',\n 'copyMatch',\n]);\nexport type ChildSafetySignalKind = z.infer<typeof ChildSafetySignalKindSchema>;\n\n/** §A9 workStatus FSM: new → triaged → reporting → actioning → operationallyResolved.\n * `operationallyResolved` NEVER deletes the case (preservation continues).\n *\n * [R12] close-lifecycle states: clicking **Close** (after the strict-closable gate passes)\n * applies the staged actions and moves the case to `processing` — it STAYS pinned/in-queue,\n * it is NEVER cleared on the click. The WORKER (quarantine saga / NCII removal / edge\n * serving-deny) flips the case to the terminal `operationallyResolved` ONLY on VERIFIED\n * completion (which clears the time-sensitive pin via onSafetyCaseClosed). If the saga\n * exhausts its retries (dead-letter), the case moves to `failed` — kept pinned, surfaced in\n * the Safety Console failed-jobs view, with a Restart that re-arms the job. Both are explicit\n * values (never derived). */\nexport const ChildSafetyWorkStatusSchema = z.enum([\n 'new',\n 'triaged',\n 'reporting',\n 'actioning',\n 'processing',\n 'failed',\n 'operationallyResolved',\n]);\nexport type ChildSafetyWorkStatus = z.infer<typeof ChildSafetyWorkStatusSchema>;\n\n/** §A9 preservationStatus FSM: preReportHold → statutoryHold → extendedHold? →\n * dispositionPending → destroyed. `statutoryHold` is set only at verified\n * completion; deletion is eligible only when every hold ref is released AND a\n * reviewed disposition job runs (no auto-delete at exactly one year). */\nexport const ChildSafetyPreservationStatusSchema = z.enum([\n 'preReportHold',\n 'statutoryHold',\n 'extendedHold',\n 'dispositionPending',\n 'destroyed',\n]);\nexport type ChildSafetyPreservationStatus = z.infer<typeof ChildSafetyPreservationStatusSchema>;\n\n/** §A9 accountActionStatus — the closure projection over `accountActionCommands`\n * (Finding-H5). A report-required case may not operationally close while\n * `pending`/`operatorDecisionPending`. */\nexport const ChildSafetyAccountActionStatusSchema = z.enum([\n 'noAccountActionRequired',\n 'operatorDecisionPending',\n 'pending',\n 'resolved',\n]);\nexport type ChildSafetyAccountActionStatus = z.infer<typeof ChildSafetyAccountActionStatusSchema>;\n\n/** §A1b reportState — derived list-projection of (reportDisposition + latest\n * submission.state) for admin-list rendering ONLY; NOT the source of truth for\n * whether a report is required (that is reportDisposition, §A9). */\nexport const ChildSafetyReportStateSchema = z.enum([\n 'reportAsSoonAsReasonablyPossible',\n 'submissionInProgress',\n 'completed',\n]);\nexport type ChildSafetyReportState = z.infer<typeof ChildSafetyReportStateSchema>;\n\n/** §A1b decisions[].kind — the append-only decision-log kind. `caseClosed` [EUAS-008]\n * is the terminal close decision carrying the structured closure record. */\nexport const ChildSafetyDecisionKindSchema = z.enum([\n 'workStatus',\n 'accountAction',\n 'reportDisposition',\n 'reasonUpdate',\n 'caseClosed',\n]);\nexport type ChildSafetyDecisionKind = z.infer<typeof ChildSafetyDecisionKindSchema>;\n\n/** §A1b accounts[].role on a case. */\nexport const ChildSafetyAccountRoleSchema = z.enum([\n 'uploader',\n 'requester',\n 'distributor',\n 'questionable',\n]);\nexport type ChildSafetyAccountRole = z.infer<typeof ChildSafetyAccountRoleSchema>;\n\n/** §A1b accounts[].subjectDisposition (per-account; distinct from the case-level\n * `reportDisposition`/ReportDisposition). */\nexport const ChildSafetyAccountSubjectDispositionSchema = z.enum([\n 'subject',\n 'questionable',\n 'excluded',\n]);\nexport type ChildSafetyAccountSubjectDisposition = z.infer<\n typeof ChildSafetyAccountSubjectDispositionSchema\n>;\n\n/** §A1b accounts[].platformAction. */\nexport const ChildSafetyAccountPlatformActionSchema = z.enum([\n 'none',\n 'watch',\n 'suspend',\n 'safetyLocked',\n 'ban',\n]);\nexport type ChildSafetyAccountPlatformAction = z.infer<\n typeof ChildSafetyAccountPlatformActionSchema\n>;\n\n/** §A1b ncmecSubmissions[].kind. */\nexport const ChildSafetyNcmecSubmissionKindSchema = z.enum([\n 'initial',\n 'supplemental',\n 'correction',\n]);\nexport type ChildSafetyNcmecSubmissionKind = z.infer<\n typeof ChildSafetyNcmecSubmissionKindSchema\n>;\n\n/** §A1b ncmecSubmissions[].completionChannel — launch = MANUAL portal only (the automated ispws API\n * is a post-launch feature, not built; the speculative live-API client was removed). */\nexport const ChildSafetyNcmecCompletionChannelSchema = z.enum(['manualPortal']);\nexport type ChildSafetyNcmecCompletionChannel = z.infer<\n typeof ChildSafetyNcmecCompletionChannelSchema\n>;\n\n/** §A1b ncmecSubmissions[].completionProofType — manual portal only at launch (no API /finish\n * reportDoneResponse; the proof is the operator-recorded portal confirmation). */\nexport const ChildSafetyNcmecCompletionProofTypeSchema = z.enum([\n 'portalConfirmation',\n]);\nexport type ChildSafetyNcmecCompletionProofType = z.infer<\n typeof ChildSafetyNcmecCompletionProofTypeSchema\n>;\n\n/** §A1b ncmecSubmissions/{id}/files[].fileInfoState. */\nexport const ChildSafetyNcmecFileInfoStateSchema = z.enum(['pending', 'sent', 'ack']);\nexport type ChildSafetyNcmecFileInfoState = z.infer<\n typeof ChildSafetyNcmecFileInfoStateSchema\n>;\n\n/** §A1b legalProcess[].kind. */\nexport const ChildSafetyLegalProcessKindSchema = z.enum([\n 'leWatch',\n 'leDataRequest',\n 'leShutdown',\n 'leDestruction',\n 'disclosure',\n]);\nexport type ChildSafetyLegalProcessKind = z.infer<typeof ChildSafetyLegalProcessKindSchema>;\n\n// ===========================================================================\n// §A1b — sourceSignalSummary (embedded privacy-safe projection on the list doc)\n// ===========================================================================\n\n/** Embedded latest-signal summary on `childSafetyCaseList` — NO content. */\nexport const ChildSafetySourceSignalSummarySchema = z.object({\n count: z.number(),\n latestKind: ChildSafetySignalKindSchema,\n latestAt: z.number(),\n}).strict();\nexport type ChildSafetySourceSignalSummary = z.infer<\n typeof ChildSafetySourceSignalSummarySchema\n>;\n\n// ===========================================================================\n// §A1b — childSafetyCaseList/{caseId} (reviewer list/metadata; NO content, NO\n// reporter identity)\n// ===========================================================================\n\nexport const ChildSafetyCaseListV1Schema = z.object({\n schemaVersion: z.literal(1),\n caseId: z.string().min(1),\n revision: z.number(),\n canonicalIncidentKey: z.string(),\n incidentClass: ChildSafetyIncidentClassSchema,\n sourceSignalSummary: ChildSafetySourceSignalSummarySchema,\n workStatus: ChildSafetyWorkStatusSchema,\n preservationStatus: ChildSafetyPreservationStatusSchema,\n ncmecStatus: NcmecSubmissionStateSchema, // §A9 NcmecSubmissionState (no `notRequired`)\n accountActionStatus: ChildSafetyAccountActionStatusSchema,\n reportDisposition: ReportDispositionSchema, // §A9 case-level reporting determination\n reviewDueAt: z.number(),\n actualKnowledgeAt: z.number().optional(),\n reportState: ChildSafetyReportStateSchema.optional(), // derived list-projection only\n submissionCompletedAt: z.number().optional(),\n preserveUntil: z.number().optional(),\n openHoldCount: z.number(),\n // Cross-links to other cases that claimed the same owning alias (a rare operator NCII-crossover\n // re-scan collision). arrayUnion'd on both cases in the intake transaction that detected the claim;\n // the console renders these as plain links on the case view. The original alias owner is kept — the\n // colliding case never `tx.create`-throws (see childSafetyOwningAliases intake). Additive/optional.\n relatedCaseIds: z.array(z.string().min(1)).optional(),\n // [H-04 V1] Set to true when a protected-reason chat report's Worker context could not be\n // resolved at intake (text-only / Worker-down). The case is still a\n // fully-valid protected case; context resolution is retried async. Absent = false (no pending\n // context). Cleared once context is attached. Surfaced in the safety console so the reviewer\n // knows to trigger a manual re-fetch if the async retry hasn't landed yet.\n contextResolutionPending: z.boolean().optional(),\n createdAt: z.number(),\n updatedAt: z.number(),\n}).strict();\nexport type ChildSafetyCaseListV1 = z.infer<typeof ChildSafetyCaseListV1Schema>;\n\n// ===========================================================================\n// §A1b — childSafetyCases/{caseId} (restricted root; childSafetyReviewer only;\n// adds the evidence manifest, the internal reason, and the lease/fencing fields)\n// ===========================================================================\n\nexport const ChildSafetyCaseV1Schema = z.object({\n schemaVersion: z.literal(1),\n caseId: z.string().min(1),\n evidenceManifestId: z.string().min(1),\n currentReasonInternal: z.string(),\n leaseOwner: z.string().min(1).optional(),\n leaseExpiresAt: z.number().optional(),\n fencingOwnerToken: z.string().min(1).optional(),\n fencingGeneration: z.number().optional(),\n // [H-04 V1] Immutable channel/message locator stored at case open when the Worker context\n // could not be resolved at intake. This is the AUTHORITATIVE source-of-truth locator that\n // the best-effort async re-fetch (and the operator's manual re-fetch) use to retrieve the\n // message text/sender. NEVER updated after creation — if context resolves, the resolved\n // context is ATTACHED to the case; this field stays unchanged as the permanent intake record.\n // Uses TargetLocatorV1 (a `guildChatMessage` / `guildInviteMessage` kind); absent on\n // media-resolved cases that went through the normal protected path with a published\n // Conversation File.\n chatMessageLocator: TargetLocatorV1Schema.optional(),\n // [H-04 V1] Mirror of the list-doc field — kept in sync so the restricted root can be\n // independently queried/checked without a join against childSafetyCaseList.\n contextResolutionPending: z.boolean().optional(),\n // [H-2] Per-leg persisted state for the two POST-COMMIT possible-minor crossover side-effects\n // (serving-deny + PhotoDNA) that `setNciiMinorAssessment` fans out when it opens/links this\n // parallel crossover case. Written via dotted-path update() (`crossoverLegs.servingDeny` etc.)\n // AFTER the case root is created in-tx, so an operator/reconciler can see which leg is\n // pending/done/failed and drive a replay — a leg failure never rolls back the committed\n // assessment, and the NCII removal clock is never touched. ABSENT on non-crossover cases (this\n // object exists only on a crossover child-safety case), and each leg field is absent when that\n // leg never applied (external / no-media target). The app also writes an in-transaction initial\n // `pending` marker, so the status enum includes `pending`.\n crossoverLegs: z.object({\n // Serving-deny leg: `pending` (in-tx marker) → `done` | `failed`.\n servingDeny: SafetyCrossoverLegStatusSchema.optional(),\n servingDeniedAt: z.number().optional(), // epoch ms; set when servingDeny → done\n servingDenyFailedAt: z.number().optional(), // epoch ms; set when servingDeny → failed\n servingDenyLastError: z.string().optional(), // error name captured on failure (never raw bytes/PII)\n // PhotoDNA leg: `pending` (in-tx marker) → `done` | `failed`.\n photoDna: SafetyCrossoverLegStatusSchema.optional(),\n photoDnaScannedAt: z.number().optional(), // epoch ms; set when photoDna → done\n photoDnaFailedAt: z.number().optional(), // epoch ms; set when photoDna → failed\n photoDnaLastError: z.string().optional(), // error name captured on failure\n }).strict().optional(),\n}).strict();\nexport type ChildSafetyCaseV1 = z.infer<typeof ChildSafetyCaseV1Schema>;\n\n// ===========================================================================\n// §A1b subcollections (append-only, NEVER arrays)\n// ===========================================================================\n\n/** …/sourceSignals/{signalId} — append-only source-signal row. */\nexport const ChildSafetySourceSignalV1Schema = z.object({\n at: z.number(),\n kind: ChildSafetySignalKindSchema,\n detector: z.string().min(1).optional(),\n sourceRef: z.string(),\n actorId: z.string().min(1).optional(),\n}).strict();\nexport type ChildSafetySourceSignalV1 = z.infer<typeof ChildSafetySourceSignalV1Schema>;\n\n/** …/decisions/{decisionId} — append-only decision-log row. The actual\n * viewed-evidence ids live in …/decisions/{decisionId}/views/{viewId}. */\nexport const ChildSafetyDecisionV1Schema = z.object({\n at: z.number(),\n actorId: z.string().min(1),\n kind: ChildSafetyDecisionKindSchema,\n from: z.string(),\n to: z.string(),\n reasonInternal: z.string(),\n reasonUserFacing: z.string().optional(),\n evidenceItemsViewedCount: z.number(),\n // [EUAS-008] present only on a `caseClosed` row — the structured operator closure record\n // (outcome / summary / note + actor / timestamp) persisted when the case is closed.\n closure: SafetyCaseClosureV1Schema.optional(),\n}).strict();\nexport type ChildSafetyDecisionV1 = z.infer<typeof ChildSafetyDecisionV1Schema>;\n\n/** …/decisions/{decisionId}/views/{viewId} — the actual viewed-evidence ids\n * (kept off the decision row itself). */\nexport const ChildSafetyDecisionViewV1Schema = z.object({\n evidenceItemId: z.string().min(1),\n at: z.number(),\n}).strict();\nexport type ChildSafetyDecisionViewV1 = z.infer<typeof ChildSafetyDecisionViewV1Schema>;\n\n/** …/accounts/{uid} — per-account case record. The per-account\n * `subjectDisposition` is distinct from the case-level `reportDisposition`. */\nexport const ChildSafetyCaseAccountV1Schema = z.object({\n role: ChildSafetyAccountRoleSchema,\n subjectDisposition: ChildSafetyAccountSubjectDispositionSchema,\n platformAction: ChildSafetyAccountPlatformActionSchema,\n reasonUserFacing: z.string(),\n reasonInternal: z.string(),\n updatedAt: z.number(),\n}).strict();\nexport type ChildSafetyCaseAccountV1 = z.infer<typeof ChildSafetyCaseAccountV1Schema>;\n\n/** …/accounts/{uid}/history/{historyId} — append-only per-account history. */\nexport const ChildSafetyCaseAccountHistoryV1Schema = z.object({\n role: ChildSafetyAccountRoleSchema,\n subjectDisposition: ChildSafetyAccountSubjectDispositionSchema,\n platformAction: ChildSafetyAccountPlatformActionSchema,\n reasonUserFacing: z.string(),\n reasonInternal: z.string(),\n at: z.number(),\n}).strict();\nexport type ChildSafetyCaseAccountHistoryV1 = z.infer<\n typeof ChildSafetyCaseAccountHistoryV1Schema\n>;\n\n/** …/ncmecSubmissions/{submissionId} — one NCMEC submission record. */\nexport const ChildSafetyNcmecSubmissionV1Schema = z.object({\n kind: ChildSafetyNcmecSubmissionKindSchema,\n state: NcmecSubmissionStateSchema, // §A9 NcmecSubmissionState\n completionChannel: ChildSafetyNcmecCompletionChannelSchema.optional(),\n submissionCompletedAt: z.number().optional(),\n completionProofType: ChildSafetyNcmecCompletionProofTypeSchema.optional(),\n completionProofRef: z.string().min(1).optional(),\n reportId: z.string().min(1).optional(),\n responseCode: z.number().optional(),\n}).strict();\nexport type ChildSafetyNcmecSubmissionV1 = z.infer<\n typeof ChildSafetyNcmecSubmissionV1Schema\n>;\n\n/** …/ncmecSubmissions/{submissionId}/files/{fileId} — per-evidence-item file row. */\nexport const ChildSafetyNcmecSubmissionFileV1Schema = z.object({\n localEvidenceItemId: z.string().min(1),\n ncmecFileId: z.string().min(1).optional(),\n md5: z.string().min(1).optional(),\n fileInfoState: ChildSafetyNcmecFileInfoStateSchema,\n}).strict();\nexport type ChildSafetyNcmecSubmissionFileV1 = z.infer<\n typeof ChildSafetyNcmecSubmissionFileV1Schema\n>;\n\n/** …/legalProcess/{eventId} — append-only legal-process event. */\nexport const ChildSafetyLegalProcessEventV1Schema = z.object({\n at: z.number(),\n kind: ChildSafetyLegalProcessKindSchema,\n verifiedBy: z.string().min(1),\n instruction: z.string(),\n handedOver: z.boolean().optional(),\n}).strict();\nexport type ChildSafetyLegalProcessEventV1 = z.infer<\n typeof ChildSafetyLegalProcessEventV1Schema\n>;\n\n// ===========================================================================\n// §A9 — setReportDisposition privileged-command input (NON-DOC embedded shape).\n// Authority = `legalDispositionAuthority` (§A11 matrix); requires fresh two-step\n// reauth. Appends to …/decisions/{decisionId} with kind:'reportDisposition'.\n// `evidenceRefs` is an array capped at MAX; it MAY be empty EXCEPT for disposition\n// 'reportRequired', which requires ≥1 (enforced by the shared\n// refineReportDispositionEvidenceRefs cross-field rule, not a field-level min).\n// ===========================================================================\n\n// The base object shape (kept as a ZodObject so the callable input can `.extend` it); the exported\n// schema below adds the TWO canonical cross-field refinements (disposition↔reason pairing +\n// reportRequired⇒evidence-present).\nconst SetReportDispositionInputV1ObjectSchema = z.object({\n caseId: z.string().min(1),\n expectedRevision: z.number(),\n disposition: ReportDispositionSchema,\n dispositionReasonCode: ReportDispositionReasonCodeSchema,\n // MAX derives from the ONE receipts cap (evidence.ts) — the callable + admin.ts use the same. No\n // field-level min: the reportRequired⇒non-empty rule lives in the shared cross-field refinement so\n // every other disposition may legally leave this empty.\n evidenceRefs: z.array(z.string().min(1)).max(MAX_MANIFEST_NCMEC_RECEIPTS),\n}).strict();\nexport const SetReportDispositionInputV1Schema = SetReportDispositionInputV1ObjectSchema\n .superRefine(refineReportDispositionReasonCode)\n .superRefine(refineReportDispositionEvidenceRefs);\nexport type SetReportDispositionInputV1 = z.infer<typeof SetReportDispositionInputV1Schema>;\n\n// The PRIVILEGED CALLABLE input (`setReportDisposition`) — extends the embedded shape with the\n// interim explicit typed confirmation (stands in for the passkey two-step until [H-17]), then applies\n// the SAME shared cross-field refinements. evidenceRefs is inherited from the base (MAX-bounded,\n// empty allowed except when disposition is 'reportRequired'). Lives beside the base shape it extends.\nexport const SetReportDispositionCallableInputSchema = SetReportDispositionInputV1ObjectSchema.extend({\n confirmation: z.literal(LEGAL_REPORTING_DISPOSITION_CONFIRMATION),\n})\n .superRefine(refineReportDispositionReasonCode)\n .superRefine(refineReportDispositionEvidenceRefs);\nexport type SetReportDispositionCallableInput = z.infer<typeof SetReportDispositionCallableInputSchema>;\n"]}
1
+ {"version":3,"file":"case.js","sourceRoot":"","sources":["../../../src/doc-schemas/safety/case.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,EAAE;AACF,gEAAgE;AAChE,4EAA4E;AAC5E,6EAA6E;AAC7E,+EAA+E;AAC/E,oEAAoE;AACpE,yDAAyD;AACzD,EAAE;AACF,+EAA+E;AAC/E,8EAA8E;AAC9E,qDAAqD;AACrD,8CAA8C;AAC9C,EAAE;AACF,sEAAsE;AACtE,2EAA2E;AAC3E,kEAAkE;AAClE,8CAA8C;AAC9C,EAAE;AACF,8EAA8E;AAC9E,4EAA4E;AAC5E,wEAAwE;AAExE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,uBAAuB,EACvB,iCAAiC,EACjC,iCAAiC,EACjC,mCAAmC,EACnC,0BAA0B,EAC1B,yBAAyB,EACzB,qBAAqB,EACrB,8BAA8B,GAC/B,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,2BAA2B,EAAE,MAAM,eAAe,CAAC;AAC5D,OAAO,EAAE,wCAAwC,EAAE,MAAM,gDAAgD,CAAC;AAE1G,8EAA8E;AAC9E,8EAA8E;AAC9E,wDAAwD;AACxD,8EAA8E;AAE9E,kDAAkD;AAClD,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,IAAI,CAAC;IACnD,cAAc;IACd,YA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C,CAAC;CAClE,CAAC;KACC,WAAW,CAAC,iCAAiC,CAAC;KAC9C,WAAW,CAAC,mCAAmC,CAAC,CAAC","sourcesContent":["// Trust & Safety — the child-safety CASE spine (Appendix A §A1b, §A9).\n//\n// The split-projection case model: a reviewer list/metadata doc\n// (`childSafetyCaseList/{caseId}` — NO content, NO reporter identity) and a\n// restricted root (`childSafetyCases/{caseId}` — adds the evidence manifest,\n// the internal reason, and the lease/fencing fields). Append-only detail lives\n// in subcollections (NEVER arrays), each enforced by writing to the\n// subcollection so there is no parent array to overflow.\n//\n// Every shape here is transcribed verbatim from the frozen Trust & Safety spec\n// (Appendix A §A1b + the §A9 state-transition rules) — no invented values, no\n// placeholders; the durable design owner is ttt-prod\n// docs/design/csam-detection-and-response.md.\n//\n// SHARED enums come from ./foundation.js (the single source for every\n// cross-cluster enum); they are NEVER redefined here. This cluster IMPORTS\n// ReportDispositionSchema, ReportDispositionReasonCodeSchema, and\n// NcmecSubmissionStateSchema from foundation.\n//\n// Collection note: this cluster introduces NEW Firestore collections; the app\n// leg (orchestrator) wires collections.ts / path-builders.ts / registry.ts.\n// The merge/alias/correlation cluster (§A2) lives in ./case-aliases.js.\n\nimport { z } from 'zod';\nimport {\n ReportDispositionSchema,\n ReportDispositionReasonCodeSchema,\n refineReportDispositionReasonCode,\n refineReportDispositionEvidenceRefs,\n NcmecSubmissionStateSchema,\n SafetyCaseClosureV1Schema,\n TargetLocatorV1Schema,\n SafetyCrossoverLegStatusSchema,\n} from './foundation.js';\nimport { MAX_MANIFEST_NCMEC_RECEIPTS } from './evidence.js';\nimport { LEGAL_REPORTING_DISPOSITION_CONFIRMATION } from '../../constants/safety-confirmation-phrases.js';\n\n// ===========================================================================\n// Cluster-local enums (§A1b + §A9). These are case-spine-specific value sets,\n// NOT cross-cluster; they live here, not in foundation.\n// ===========================================================================\n\n/** Incident classification on the case (§A1b). */\nexport const ChildSafetyIncidentClassSchema = z.enum([\n 'apparentCsam',\n 'enticement',\n 'minorSexTrafficking',\n 'sextortion',\n 'csamSolicitation',\n 'imminentCsea',\n 'nonReportableSafety',\n]);\nexport type ChildSafetyIncidentClass = z.infer<typeof ChildSafetyIncidentClassSchema>;\n\n/** Source-signal kind (shared by the case `sourceSignalSummary` projection and\n * the `…/sourceSignals/{signalId}` append-only rows). */\nexport const ChildSafetySignalKindSchema = z.enum([\n 'hashMatch',\n 'report',\n 'aiFlag',\n 'manual',\n 'copyMatch',\n]);\nexport type ChildSafetySignalKind = z.infer<typeof ChildSafetySignalKindSchema>;\n\n/** §A9 workStatus FSM: new → triaged → reporting → actioning → operationallyResolved.\n * `operationallyResolved` NEVER deletes the case (preservation continues).\n *\n * [R12] close-lifecycle states: clicking **Close** (after the strict-closable gate passes)\n * applies the staged actions and moves the case to `processing` — it STAYS pinned/in-queue,\n * it is NEVER cleared on the click. The WORKER (quarantine saga / NCII removal / edge\n * serving-deny) flips the case to the terminal `operationallyResolved` ONLY on VERIFIED\n * completion (which clears the time-sensitive pin via onSafetyCaseClosed). If the saga\n * exhausts its retries (dead-letter), the case moves to `failed` — kept pinned, surfaced in\n * the Safety Console failed-jobs view, with a Restart that re-arms the job. Both are explicit\n * values (never derived). */\nexport const ChildSafetyWorkStatusSchema = z.enum([\n 'new',\n 'triaged',\n 'reporting',\n 'actioning',\n 'processing',\n 'failed',\n 'operationallyResolved',\n]);\nexport type ChildSafetyWorkStatus = z.infer<typeof ChildSafetyWorkStatusSchema>;\n\n/** §A9 preservationStatus FSM: preReportHold → statutoryHold → extendedHold? →\n * dispositionPending → destroyed. `statutoryHold` is set only at verified\n * completion; deletion is eligible only when every hold ref is released AND a\n * reviewed disposition job runs (no auto-delete at exactly one year). */\nexport const ChildSafetyPreservationStatusSchema = z.enum([\n 'preReportHold',\n 'statutoryHold',\n 'extendedHold',\n 'dispositionPending',\n 'destroyed',\n]);\nexport type ChildSafetyPreservationStatus = z.infer<typeof ChildSafetyPreservationStatusSchema>;\n\n/** §A9 accountActionStatus — the closure projection over `accountActionCommands`\n * (Finding-H5). A report-required case may not operationally close while\n * `pending`/`operatorDecisionPending`. */\nexport const ChildSafetyAccountActionStatusSchema = z.enum([\n 'noAccountActionRequired',\n 'operatorDecisionPending',\n 'pending',\n 'resolved',\n]);\nexport type ChildSafetyAccountActionStatus = z.infer<typeof ChildSafetyAccountActionStatusSchema>;\n\n/** §A1b reportState — derived list-projection of (reportDisposition + latest\n * submission.state) for admin-list rendering ONLY; NOT the source of truth for\n * whether a report is required (that is reportDisposition, §A9). */\nexport const ChildSafetyReportStateSchema = z.enum([\n 'reportAsSoonAsReasonablyPossible',\n 'submissionInProgress',\n 'completed',\n]);\nexport type ChildSafetyReportState = z.infer<typeof ChildSafetyReportStateSchema>;\n\n/** §A1b decisions[].kind — the append-only decision-log kind. `caseClosed` [EUAS-008]\n * is the terminal close decision carrying the structured closure record. */\nexport const ChildSafetyDecisionKindSchema = z.enum([\n 'workStatus',\n 'accountAction',\n 'reportDisposition',\n 'reasonUpdate',\n 'caseClosed',\n]);\nexport type ChildSafetyDecisionKind = z.infer<typeof ChildSafetyDecisionKindSchema>;\n\n/** §A1b accounts[].role on a case. */\nexport const ChildSafetyAccountRoleSchema = z.enum([\n 'uploader',\n 'requester',\n 'distributor',\n 'questionable',\n]);\nexport type ChildSafetyAccountRole = z.infer<typeof ChildSafetyAccountRoleSchema>;\n\n/** §A1b accounts[].subjectDisposition (per-account; distinct from the case-level\n * `reportDisposition`/ReportDisposition). */\nexport const ChildSafetyAccountSubjectDispositionSchema = z.enum([\n 'subject',\n 'questionable',\n 'excluded',\n]);\nexport type ChildSafetyAccountSubjectDisposition = z.infer<\n typeof ChildSafetyAccountSubjectDispositionSchema\n>;\n\n/** §A1b accounts[].platformAction. */\nexport const ChildSafetyAccountPlatformActionSchema = z.enum([\n 'none',\n 'watch',\n 'suspend',\n 'safetyLocked',\n 'ban',\n]);\nexport type ChildSafetyAccountPlatformAction = z.infer<\n typeof ChildSafetyAccountPlatformActionSchema\n>;\n\n/** §A1b ncmecSubmissions[].kind. */\nexport const ChildSafetyNcmecSubmissionKindSchema = z.enum([\n 'initial',\n 'supplemental',\n 'correction',\n]);\nexport type ChildSafetyNcmecSubmissionKind = z.infer<\n typeof ChildSafetyNcmecSubmissionKindSchema\n>;\n\n/** §A1b ncmecSubmissions[].completionChannel — launch = MANUAL portal only (the automated ispws API\n * is a post-launch feature, not built; the speculative live-API client was removed). */\nexport const ChildSafetyNcmecCompletionChannelSchema = z.enum(['manualPortal']);\nexport type ChildSafetyNcmecCompletionChannel = z.infer<\n typeof ChildSafetyNcmecCompletionChannelSchema\n>;\n\n/** §A1b ncmecSubmissions[].completionProofType — manual portal only at launch (no API /finish\n * reportDoneResponse; the proof is the operator-recorded portal confirmation). */\nexport const ChildSafetyNcmecCompletionProofTypeSchema = z.enum([\n 'portalConfirmation',\n]);\nexport type ChildSafetyNcmecCompletionProofType = z.infer<\n typeof ChildSafetyNcmecCompletionProofTypeSchema\n>;\n\n/** §A1b ncmecSubmissions/{id}/files[].fileInfoState. */\nexport const ChildSafetyNcmecFileInfoStateSchema = z.enum(['pending', 'sent', 'ack']);\nexport type ChildSafetyNcmecFileInfoState = z.infer<\n typeof ChildSafetyNcmecFileInfoStateSchema\n>;\n\n/** §A1b legalProcess[].kind. */\nexport const ChildSafetyLegalProcessKindSchema = z.enum([\n 'leWatch',\n 'leDataRequest',\n 'leShutdown',\n 'leDestruction',\n 'disclosure',\n]);\nexport type ChildSafetyLegalProcessKind = z.infer<typeof ChildSafetyLegalProcessKindSchema>;\n\n// ===========================================================================\n// §A1b — sourceSignalSummary (embedded privacy-safe projection on the list doc)\n// ===========================================================================\n\n/** Embedded latest-signal summary on `childSafetyCaseList` — NO content. */\nexport const ChildSafetySourceSignalSummarySchema = z.object({\n count: z.number(),\n latestKind: ChildSafetySignalKindSchema,\n latestAt: z.number(),\n}).strict();\nexport type ChildSafetySourceSignalSummary = z.infer<\n typeof ChildSafetySourceSignalSummarySchema\n>;\n\n// ===========================================================================\n// §A1b — childSafetyCaseList/{caseId} (reviewer list/metadata; NO content, NO\n// reporter identity)\n// ===========================================================================\n\nexport const ChildSafetyCaseListV1Schema = z.object({\n schemaVersion: z.literal(1),\n caseId: z.string().min(1),\n revision: z.number(),\n canonicalIncidentKey: z.string(),\n incidentClass: ChildSafetyIncidentClassSchema,\n sourceSignalSummary: ChildSafetySourceSignalSummarySchema,\n workStatus: ChildSafetyWorkStatusSchema,\n preservationStatus: ChildSafetyPreservationStatusSchema,\n ncmecStatus: NcmecSubmissionStateSchema, // §A9 NcmecSubmissionState (no `notRequired`)\n accountActionStatus: ChildSafetyAccountActionStatusSchema,\n reportDisposition: ReportDispositionSchema, // §A9 case-level reporting determination\n reviewDueAt: z.number(),\n actualKnowledgeAt: z.number().optional(),\n reportState: ChildSafetyReportStateSchema.optional(), // derived list-projection only\n submissionCompletedAt: z.number().optional(),\n preserveUntil: z.number().optional(),\n openHoldCount: z.number(),\n // Cross-links to other cases that claimed the same owning alias (a rare operator NCII-crossover\n // re-scan collision). arrayUnion'd on both cases in the intake transaction that detected the claim;\n // the console renders these as plain links on the case view. The original alias owner is kept — the\n // colliding case never `tx.create`-throws (see childSafetyOwningAliases intake). Additive/optional.\n relatedCaseIds: z.array(z.string().min(1)).optional(),\n // [H-04 V1] Set to true when a protected-reason chat report's Worker context could not be\n // resolved at intake (text-only / Worker-down). The case is still a\n // fully-valid protected case; context resolution is retried async. Absent = false (no pending\n // context). Cleared once context is attached. Surfaced in the safety console so the reviewer\n // knows to trigger a manual re-fetch if the async retry hasn't landed yet.\n contextResolutionPending: z.boolean().optional(),\n // Test-list drill lane (DJ ruling 2026-07-28): true ⇔ every validated PhotoDNA match on this\n // case matched ONLY Microsoft's published TEST hash list (the detector echoes listId \"Test\"),\n // never a production list. A drill case is reviewable and closeable through the normal guided\n // flow but carries NO reporting obligation: the converge path sets no actualKnowledgeAt, no\n // reportRequired, enqueues no NCMEC submission, and arms no report-clock monitors — and the\n // `notRequired` disposition invariant exempts it (a test-image match is definitionally not\n // CSAM; auto-filing a CyberTipline report over it would be wrong). CLEARED (deleted) the\n // moment a real-list match joins the case — real evidence instantly restores the full\n // obligation machinery. Absent = real case.\n testListDrill: z.literal(true).optional(),\n createdAt: z.number(),\n updatedAt: z.number(),\n}).strict();\nexport type ChildSafetyCaseListV1 = z.infer<typeof ChildSafetyCaseListV1Schema>;\n\n// ===========================================================================\n// §A1b — childSafetyCases/{caseId} (restricted root; childSafetyReviewer only;\n// adds the evidence manifest, the internal reason, and the lease/fencing fields)\n// ===========================================================================\n\nexport const ChildSafetyCaseV1Schema = z.object({\n schemaVersion: z.literal(1),\n caseId: z.string().min(1),\n evidenceManifestId: z.string().min(1),\n currentReasonInternal: z.string(),\n leaseOwner: z.string().min(1).optional(),\n leaseExpiresAt: z.number().optional(),\n fencingOwnerToken: z.string().min(1).optional(),\n fencingGeneration: z.number().optional(),\n // [H-04 V1] Immutable channel/message locator stored at case open when the Worker context\n // could not be resolved at intake. This is the AUTHORITATIVE source-of-truth locator that\n // the best-effort async re-fetch (and the operator's manual re-fetch) use to retrieve the\n // message text/sender. NEVER updated after creation — if context resolves, the resolved\n // context is ATTACHED to the case; this field stays unchanged as the permanent intake record.\n // Uses TargetLocatorV1 (a `guildChatMessage` / `guildInviteMessage` kind); absent on\n // media-resolved cases that went through the normal protected path with a published\n // Conversation File.\n chatMessageLocator: TargetLocatorV1Schema.optional(),\n // [H-04 V1] Mirror of the list-doc field — kept in sync so the restricted root can be\n // independently queried/checked without a join against childSafetyCaseList.\n contextResolutionPending: z.boolean().optional(),\n // [H-2] Per-leg persisted state for the two POST-COMMIT possible-minor crossover side-effects\n // (serving-deny + PhotoDNA) that `setNciiMinorAssessment` fans out when it opens/links this\n // parallel crossover case. Written via dotted-path update() (`crossoverLegs.servingDeny` etc.)\n // AFTER the case root is created in-tx, so an operator/reconciler can see which leg is\n // pending/done/failed and drive a replay — a leg failure never rolls back the committed\n // assessment, and the NCII removal clock is never touched. ABSENT on non-crossover cases (this\n // object exists only on a crossover child-safety case), and each leg field is absent when that\n // leg never applied (external / no-media target). The app also writes an in-transaction initial\n // `pending` marker, so the status enum includes `pending`.\n crossoverLegs: z.object({\n // Serving-deny leg: `pending` (in-tx marker) → `done` | `failed`.\n servingDeny: SafetyCrossoverLegStatusSchema.optional(),\n servingDeniedAt: z.number().optional(), // epoch ms; set when servingDeny → done\n servingDenyFailedAt: z.number().optional(), // epoch ms; set when servingDeny → failed\n servingDenyLastError: z.string().optional(), // error name captured on failure (never raw bytes/PII)\n // PhotoDNA leg: `pending` (in-tx marker) → `done` | `failed`.\n photoDna: SafetyCrossoverLegStatusSchema.optional(),\n photoDnaScannedAt: z.number().optional(), // epoch ms; set when photoDna → done\n photoDnaFailedAt: z.number().optional(), // epoch ms; set when photoDna → failed\n photoDnaLastError: z.string().optional(), // error name captured on failure\n }).strict().optional(),\n}).strict();\nexport type ChildSafetyCaseV1 = z.infer<typeof ChildSafetyCaseV1Schema>;\n\n// ===========================================================================\n// §A1b subcollections (append-only, NEVER arrays)\n// ===========================================================================\n\n/** …/sourceSignals/{signalId} — append-only source-signal row. */\nexport const ChildSafetySourceSignalV1Schema = z.object({\n at: z.number(),\n kind: ChildSafetySignalKindSchema,\n detector: z.string().min(1).optional(),\n sourceRef: z.string(),\n actorId: z.string().min(1).optional(),\n}).strict();\nexport type ChildSafetySourceSignalV1 = z.infer<typeof ChildSafetySourceSignalV1Schema>;\n\n/** …/decisions/{decisionId} — append-only decision-log row. The actual\n * viewed-evidence ids live in …/decisions/{decisionId}/views/{viewId}. */\nexport const ChildSafetyDecisionV1Schema = z.object({\n at: z.number(),\n actorId: z.string().min(1),\n kind: ChildSafetyDecisionKindSchema,\n from: z.string(),\n to: z.string(),\n reasonInternal: z.string(),\n reasonUserFacing: z.string().optional(),\n evidenceItemsViewedCount: z.number(),\n // [EUAS-008] present only on a `caseClosed` row — the structured operator closure record\n // (outcome / summary / note + actor / timestamp) persisted when the case is closed.\n closure: SafetyCaseClosureV1Schema.optional(),\n}).strict();\nexport type ChildSafetyDecisionV1 = z.infer<typeof ChildSafetyDecisionV1Schema>;\n\n/** …/decisions/{decisionId}/views/{viewId} — the actual viewed-evidence ids\n * (kept off the decision row itself). */\nexport const ChildSafetyDecisionViewV1Schema = z.object({\n evidenceItemId: z.string().min(1),\n at: z.number(),\n}).strict();\nexport type ChildSafetyDecisionViewV1 = z.infer<typeof ChildSafetyDecisionViewV1Schema>;\n\n/** …/accounts/{uid} — per-account case record. The per-account\n * `subjectDisposition` is distinct from the case-level `reportDisposition`. */\nexport const ChildSafetyCaseAccountV1Schema = z.object({\n role: ChildSafetyAccountRoleSchema,\n subjectDisposition: ChildSafetyAccountSubjectDispositionSchema,\n platformAction: ChildSafetyAccountPlatformActionSchema,\n reasonUserFacing: z.string(),\n reasonInternal: z.string(),\n updatedAt: z.number(),\n}).strict();\nexport type ChildSafetyCaseAccountV1 = z.infer<typeof ChildSafetyCaseAccountV1Schema>;\n\n/** …/accounts/{uid}/history/{historyId} — append-only per-account history. */\nexport const ChildSafetyCaseAccountHistoryV1Schema = z.object({\n role: ChildSafetyAccountRoleSchema,\n subjectDisposition: ChildSafetyAccountSubjectDispositionSchema,\n platformAction: ChildSafetyAccountPlatformActionSchema,\n reasonUserFacing: z.string(),\n reasonInternal: z.string(),\n at: z.number(),\n}).strict();\nexport type ChildSafetyCaseAccountHistoryV1 = z.infer<\n typeof ChildSafetyCaseAccountHistoryV1Schema\n>;\n\n/** …/ncmecSubmissions/{submissionId} — one NCMEC submission record. */\nexport const ChildSafetyNcmecSubmissionV1Schema = z.object({\n kind: ChildSafetyNcmecSubmissionKindSchema,\n state: NcmecSubmissionStateSchema, // §A9 NcmecSubmissionState\n completionChannel: ChildSafetyNcmecCompletionChannelSchema.optional(),\n submissionCompletedAt: z.number().optional(),\n completionProofType: ChildSafetyNcmecCompletionProofTypeSchema.optional(),\n completionProofRef: z.string().min(1).optional(),\n reportId: z.string().min(1).optional(),\n responseCode: z.number().optional(),\n}).strict();\nexport type ChildSafetyNcmecSubmissionV1 = z.infer<\n typeof ChildSafetyNcmecSubmissionV1Schema\n>;\n\n/** …/ncmecSubmissions/{submissionId}/files/{fileId} — per-evidence-item file row. */\nexport const ChildSafetyNcmecSubmissionFileV1Schema = z.object({\n localEvidenceItemId: z.string().min(1),\n ncmecFileId: z.string().min(1).optional(),\n md5: z.string().min(1).optional(),\n fileInfoState: ChildSafetyNcmecFileInfoStateSchema,\n}).strict();\nexport type ChildSafetyNcmecSubmissionFileV1 = z.infer<\n typeof ChildSafetyNcmecSubmissionFileV1Schema\n>;\n\n/** …/legalProcess/{eventId} — append-only legal-process event. */\nexport const ChildSafetyLegalProcessEventV1Schema = z.object({\n at: z.number(),\n kind: ChildSafetyLegalProcessKindSchema,\n verifiedBy: z.string().min(1),\n instruction: z.string(),\n handedOver: z.boolean().optional(),\n}).strict();\nexport type ChildSafetyLegalProcessEventV1 = z.infer<\n typeof ChildSafetyLegalProcessEventV1Schema\n>;\n\n// ===========================================================================\n// §A9 — setReportDisposition privileged-command input (NON-DOC embedded shape).\n// Authority = `legalDispositionAuthority` (§A11 matrix); requires fresh two-step\n// reauth. Appends to …/decisions/{decisionId} with kind:'reportDisposition'.\n// `evidenceRefs` is an array capped at MAX; it MAY be empty EXCEPT for disposition\n// 'reportRequired', which requires ≥1 (enforced by the shared\n// refineReportDispositionEvidenceRefs cross-field rule, not a field-level min).\n// ===========================================================================\n\n// The base object shape (kept as a ZodObject so the callable input can `.extend` it); the exported\n// schema below adds the TWO canonical cross-field refinements (disposition↔reason pairing +\n// reportRequired⇒evidence-present).\nconst SetReportDispositionInputV1ObjectSchema = z.object({\n caseId: z.string().min(1),\n expectedRevision: z.number(),\n disposition: ReportDispositionSchema,\n dispositionReasonCode: ReportDispositionReasonCodeSchema,\n // MAX derives from the ONE receipts cap (evidence.ts) — the callable + admin.ts use the same. No\n // field-level min: the reportRequired⇒non-empty rule lives in the shared cross-field refinement so\n // every other disposition may legally leave this empty.\n evidenceRefs: z.array(z.string().min(1)).max(MAX_MANIFEST_NCMEC_RECEIPTS),\n}).strict();\nexport const SetReportDispositionInputV1Schema = SetReportDispositionInputV1ObjectSchema\n .superRefine(refineReportDispositionReasonCode)\n .superRefine(refineReportDispositionEvidenceRefs);\nexport type SetReportDispositionInputV1 = z.infer<typeof SetReportDispositionInputV1Schema>;\n\n// The PRIVILEGED CALLABLE input (`setReportDisposition`) — extends the embedded shape with the\n// interim explicit typed confirmation (stands in for the passkey two-step until [H-17]), then applies\n// the SAME shared cross-field refinements. evidenceRefs is inherited from the base (MAX-bounded,\n// empty allowed except when disposition is 'reportRequired'). Lives beside the base shape it extends.\nexport const SetReportDispositionCallableInputSchema = SetReportDispositionInputV1ObjectSchema.extend({\n confirmation: z.literal(LEGAL_REPORTING_DISPOSITION_CONFIRMATION),\n})\n .superRefine(refineReportDispositionReasonCode)\n .superRefine(refineReportDispositionEvidenceRefs);\nexport type SetReportDispositionCallableInput = z.infer<typeof SetReportDispositionCallableInputSchema>;\n"]}