Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.encoreos.io/llms.txt

Use this file to discover all available pages before exploring further.

Feature ID: PF-44
Spec: PF-44-data-export-compliance
Status: ✅ Implemented
Spec Reference: PF-44-data-export-compliance.md
Last Updated: 2026-02-14

Overview

PF-44 provides a standardized data export and compliance framework. It depends on PF-04 (Audit Logging), PF-11 (Document Management), and PF-30 (Permissions). Export events are published to PF-04 for compliance auditing.

Dependencies

DependencyTypeStatusPurpose
PF-04 (Audit Logging)Platform✅ IntegratedAll export requests and completions audited via pf_audit_logs
PF-11 (Document Management)Platform✅ IntegratedExport files stored in Supabase Storage (pf-exports bucket)
PF-30 (Permissions)Platform✅ IntegratedPages gated via PermissionGate (pf.export_requests.view, pf.export_templates.manage)
PF-12 (Reporting Engine)Platform🔄 DeferredReport generation logic for exports (can integrate when PF-12 matures)
PF-10 (Notifications)Platform🔄 DeferredEmail notification on export completion

Event Contracts (PF-04)

PF-44 publishes the following audit events to pf_audit_logs:
EventPublisherPayload (abbreviated)PII/PHI note
export_request_completedprocess-export edge fnorganization_id, export_request_id, export_type, export_format, entity_types, row_count, file_size_bytes, execution_time_ms, pii_phi_filteredFilter criteria sanitized; no raw PII logged
export_request_failedprocess-export edge fnorganization_id, export_request_id, error (sanitized)Error messages sanitized

API / Edge Functions

  • process-export – Async export processor: fetches data, applies PII/PHI filtering, generates CSV/JSON, uploads to storage, creates signed URLs, logs audit events.

Permission Keys

Permission KeyDescriptionRoles
pf.export_requests.viewView export historyorg_admin, finance_admin, staff
pf.export_requests.createCreate new export requestsorg_admin, finance_admin
pf.export_templates.manageCreate/edit/delete export templatesorg_admin, finance_admin

Integration Matrix

PF-44 is Platform Foundation only (no cross-core integration). This doc satisfies spec integration documentation requirements.