Skip to content

feat: PII Export & Delete Workflow (GDPR-ready) - fixes #76#906

Open
tarai-dl wants to merge 1 commit intorohitdash08:mainfrom
tarai-dl:fix/76-pii-export-delete
Open

feat: PII Export & Delete Workflow (GDPR-ready) - fixes #76#906
tarai-dl wants to merge 1 commit intorohitdash08:mainfrom
tarai-dl:fix/76-pii-export-delete

Conversation

@tarai-dl
Copy link
Copy Markdown

Summary

Implements GDPR-compliant PII export and deletion workflow as described in #76.

Changes

  • **** (GET): Export all user data as JSON or CSV (GDPR Article 20 - Right to data portability)
  • **** (POST): Permanently delete all user data with confirmation required (GDPR Article 17 - Right to erasure)
  • Audit trail: Both operations are logged to the existing table
  • Tests: Comprehensive test suite for both endpoints

Technical Details

  • Respects foreign key ordering during deletion (reminders → expenses → recurring → bills → categories → user)
  • Export includes all user data: profile, categories, expenses, recurring expenses, bills, reminders
  • CSV export available via query parameter
  • Deletion requires in request body for safety
  • All operations logged to audit trail with timestamps

Acceptance Criteria

  • Export package generation (JSON & CSV)
  • Irreversible deletion workflow
  • Audit trail logging
  • Tests included

Closes #76

- Add /privacy/export endpoint (JSON & CSV) for GDPR Article 20 data portability
- Add /privacy/delete endpoint with confirmation for GDPR Article 17 right to erasure
- Audit trail logging for both export and deletion operations
- Comprehensive test suite for privacy endpoints
- Respects foreign key ordering during deletion
@tarai-dl tarai-dl requested a review from rohitdash08 as a code owner April 16, 2026 23:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PII Export & Delete Workflow (GDPR-ready)

1 participant