Skip to main content

Retention Periods

AI-Corporate offers the possibility to set retention periods per collection. A collection is a set of similar data. For example, there is a collection of "Organizations" and a collection of "Chats".

For some collections, this option is not available. This is the case for data where it is not logical for them to automatically expire after an end date, or where other legal retention periods apply.

Setting Retention Periods

The organization_admin can set retention periods in the environment, under the "Data retention" section.

Default settings are already in place, but these can be modified per environment. Examples of configurable periods:

  • project data, chats, and chat messages will be deleted after X months
  • team or project group data is deleted annually or after project completion
  • user and employee data is deleted X years after end of employment/contract, in accordance with GDPR and company policy

How Data Retention Works

When a new record is added to the collection, an automatic expiration date is immediately calculated based on the settings in Data retention.

For example, a chat is added on April 18, 2024, and the data retention is set to 3 months. Then the record is assigned an expiration date of July 18, 2024.

We use the Firebase TTL policy functionality. Firebase detects the expiration date field and automatically cleans up records that are past the expiration date. This occurs approximately 24 hours after the expiration date.

Time To Live Policy Firebase