Skip to main content

Retention

The Retention screen lets you define how long each kind of data is kept, run the retention now, erase the data of a data subject (right to be forgotten) and place or release legal holds. Portal path: /data/retention. Data stewards, security officers and tenant administrators use it.

What the screen shows​

The header holds the Run retention now button; its JSON report appears under the header after a run.

Three tabs:

  • Policies: the Retention policies table with Resource type, TTL (days), Action, Enabled, Updated. The New policy form has Resource type (required: sessions, memory, media, documents, usage_raw, telemetry), TTL (days) (required, 365), Action (required: erase or archive) and Enabled (checked). There is one policy per resource type: creating it again updates it.
  • Subject erasure: a form with Subject id (required), Reason (gdpr_art_17), Dry run (checked) and Include documents, and its result panel.
  • Legal hold: a form with Resource type, Resource id, Subject id, Reason (required) and Active (checked), and its result panel.

Actions​

Button or actionWhat it doesAPI callRoles
Run retention nowApplies every enabled policy now and shows the reportPOST /v1/retention/runtenant_admin, security_officer, data_steward
Refresh icon (Policies)Reloads the policiesGET /v1/retention/policiesany tenant user
New policy > CreateCreates or updates the policy of a resource typePOST /v1/retention/policiestenant_admin, security_officer, data_steward
Run (Subject erasure)Erases, or simulates the erasure of, the data of a personPOST /v1/retention/erasetenant_admin, security_officer, data_steward
Run (Legal hold)Places a hold on a resource or a person; the data stops expiringPOST /v1/retention/legal-holdtenant_admin, security_officer, data_steward

Roles​

The portal shows every button. The Control Plane (services/control-plane/src/eai/domains/retention/__init__.py, constant ADMIN) accepts the writes only from tenant_admin, security_officer and data_steward; others get forbidden. Every run, erasure and hold is audited.

Typical tasks​

Keep the sessions for one year​

  1. Create the policy. Without a policy, data is kept. Open Policies, click New policy, choose Resource type sessions, TTL (days) 365, Action erase, then Create.

    Expected result: the toast "Created" and the row in Retention policies.

    If it fails: invalid_request with resource_type lists the allowed types.

  2. Run it once. Click Run retention now.

    Expected result: the toast "Done" and a report counting the processed items and the items skipped by a legal hold.

    If it fails: forbidden means your role is not allowed to run retention.

Erase the data of a person​

  1. Simulate first. A dry run lists what would be erased without erasing. Open Subject erasure, type the Subject id, keep Dry run checked, then Run.

    Expected result: status dry_run with the counts in deleted and skipped_legal_hold.

    If it fails: check the subject id (the user id the platform records).

  2. Erase. Uncheck Dry run, check Include documents if the documents created by the person must go too, then Run.

    danger

    Without Dry run, the erasure cannot be undone. The audit trail and the financial usage records are kept by law; the answer lists them in retained.

    Expected result: status completed.

    If it fails: status incomplete means an external system did not erase; the external block names it.

Freeze the data of a litigation​

  1. Place the hold. A hold stops retention and deletion. Open Legal hold, fill Subject id (or Resource type and Resource id), a Reason, keep Active checked, then Run.

    Expected result: the hold record with active true.

    If it fails: invalid_request with required means neither a subject nor a resource type and id were given.

Troubleshooting​

SymptomCauseFix
forbidden (403) with required_rolesYour role is not tenant_admin, security_officer or data_stewardAsk a data steward
invalid_request (400) with resource_typeUnknown resource typeUse one of the allowed types
invalid_request (400) with actionThe action is not erase or archiveChoose erase or archive
invalid_request (400) with required reasonA new hold needs a reasonFill Reason
not_found (404) with legal_holdThe hold id to release does not existCheck the id of the hold
A deletion elsewhere answers legal_hold (409)A hold protects the itemRelease it here with Active unchecked