Integration health records are stored to track the status of external integration calls. These records can grow over time. A management command is provided to clean up old records.
To delete integration health records older than 30 days (default):
python manage.py cleanup_integration_health_recordsTo specify a custom retention period:
python manage.py cleanup_integration_health_records --days=60To prevent the IntegrationHealthRecord table from growing unbounded, schedule the cleanup command to run periodically using cron or your preferred task scheduler.
Example cron entry (runs daily at 3 AM):
0 3 * * * cd /path/to/flagsmith && python manage.py cleanup_integration_health_records