Api reference
components.compliance.public.commands ¶
alert_unreviewed_gdpr_deletion_batches ¶
alert_unreviewed_gdpr_deletion_batches ¶
Send Slack alerts for unreviewed GDPR deletion batches per bucket type.
Source code in components/compliance/public/commands/alert_unreviewed_gdpr_deletion_batches.py
create_gdpr_deletion_batch_for_data_bucket ¶
create_gdpr_deletion_batch_for_data_bucket ¶
Create GDPR deletion batches for a given data bucket, chunked by max-batch-size.
Source code in components/compliance/public/commands/create_gdpr_deletion_batch_for_data_bucket.py
create_gdpr_deletion_records_for_data_bucket ¶
create_gdpr_deletion_records_for_data_bucket ¶
Create GDPR deletion records for a given bucket type using bulk operations.
Source code in components/compliance/public/commands/create_gdpr_deletion_records_for_data_bucket.py
purge_gdpr_compliance_data ¶
purge_gdpr_compliance_data_command ¶
Purge all GDPR deletion records, batches, and orphan profiles for a bucket type.
Source code in components/compliance/public/commands/purge_gdpr_compliance_data.py
components.compliance.public.entities ¶
ComplianceProfile
dataclass
¶
Bases: DataClassJsonMixin
Entity representing a compliance profile model
GdprDeletionBatch
dataclass
¶
GdprDeletionBatch(
id,
bucket_type,
deletion_records,
reviewed_status,
reviewed_at,
reviewed_by,
reviewed_reason,
created_at,
updated_at,
records_count_for_list=0,
failed_records_count=0,
manually_reviewed_count=0,
rejected_records_count=0,
total_records_count=0,
)
Bases: DataClassJsonMixin
Entity representing a GDPR deletion batch model
GdprDeletionBatchProgress
dataclass
¶
GdprDeletionRecord
dataclass
¶
GdprDeletionRecord(
id,
compliance_profile_id,
compliance_profile,
bucket_type,
deletion_batch_id,
deletion_scheduled_at,
deletion_applied_at,
created_at,
updated_at,
accepted_for_deletion=None,
is_manually_reviewed=None,
deletion_error=None,
)
Bases: DataClassJsonMixin
Entity representing a GDPR deletion record model
components.compliance.public.enums ¶
ComplianceDataBucketType ¶
Bases: AlanBaseEnum
Type of data bucket to be considered for GDPR compliance deletion process
components.compliance.public.gdpr_access ¶
Helpers for running Metabase saved questions and uploading files for GDPR access requests.
run_metabase_questions_for_user ¶
Run a sequence of Metabase questions parameterized with user_id, saving each as CSV.
Output filenames follow the pattern
{file_prefix}{short_name}.csv}_{iso8601_timestamp
Pass an explicit timestamp to share it across multiple export functions in one batch. If omitted, a timestamp is generated at call time.
Returns:
| Type | Description |
|---|---|
list[str]
|
List of written file paths. |
Source code in components/compliance/public/gdpr_access.py
upload_files_to_gdpr_folder ¶
Upload GDPR access files to a new Dataroom folder.
Creates folder 'GDPR access - {app_name} - {user_id}' inside the GDPR root folder (ID 2041) and uploads all files to it.
Returns:
| Type | Description |
|---|---|
DataroomFileData
|
DataroomFileData for the created folder. |