Best practice for automated form data cleanup in Xperience by Kentico

In Kentico Xperience 13, we implemented automated form data cleanup using a custom scheduled task. We extended forms with additional configuration that allowed editors to define a retention period (e.g. delete or anonymize form submissions after X days), and the scheduled task processed the data accordingly.

In Xperience by Kentico, scheduled tasks are still available and seem like a natural fit for recurring maintenance operations such as bulk data cleanup. However, the platform now also introduces the option to build custom automation steps, which could potentially provide a more user-friendly and configurable approach for customers.

I am currently evaluating the best architectural approach for the following use case:

  • Allow customers to configure automatic cleanup (delete/anonymize) of form submissions after a configurable retention period
  • Keep the solution editor-friendly and maintainable

  • Align with recommended Xperience by Kentico patterns and long-term platform direction

My questions:

  • Do you consider scheduled tasks still the preferred approach for this type of recurring, system-wide data maintenance?

  • Has anyone implemented a similar solution using custom automation steps, and if so, how well does that scale for bulk form data processing?

  • Are there any recommended patterns (or pitfalls) when choosing between scheduled tasks and custom automation steps for data retention scenarios?

Any experience, guidance, or architectural insight would be greatly appreciated.

Tags:
Customer data Data privacy Marketing automation Form Builder
0

Answers

Accepted answer

Hey Jeroen,
based on my experience with Xperience, I would lean towards using scheduled tasks for this kind of requirement.

Automated form data cleanup feels like a system-level, recurring maintenance operation rather than something driven by individual contact actions. Scheduled tasks are a good fit for that. They are designed for bulk operations, can run on a defined schedule, and can also be triggered manually, which is useful both for testing and operational control.

When it comes to automations, my understanding is that they are primarily intended for marketing or contact-centric workflows. They typically react to a specific contact’s activity, such as a form submission or registration, and execute logic per contact. Because of that per-contact nature, I would be cautious about using automations for system-wide or bulk data processing like retention-based cleanup.

One aspect I would also look at, aside from how the cleanup is triggered, is how the cleanup itself is implemented. From your description, it sounds like custom logic may be involved, which is perfectly reasonable. That said, it might be worth considering the built-in data protection features as well. Xperience provides a data protection framework that can delete or anonymize personal data, including form submissions, in a structured and GDPR-aligned way.

If it were my solution, I would use a scheduled task as the main trigger, process submissions based on the configured retention period, and consider integrating with the data protection APIs to stay aligned with platform patterns and long-term maintainability.

Out of curiosity, are you currently handling the cleanup fully custom, or are you already leveraging the data protection framework?

0

I completely agree with Milan's suggestion!

the platform now also introduces the option to build custom automation steps

That isn't true as of the December 2026 Refresh (v31.0.0). The automation engine is all internal and there are no supported APIs (some are "pub-ternal" which are public but in .Internal namespaces) for creating custom automation steps or logic.

0

Thanks both for the feedback and insights 🙌

I should probably admit that my thoughts around custom automation steps were a bit optimistic 😄 I had been using the documentation MCP to sanity check my assumptions and clearly wanted to believe very badly that this extensibility already existed. Lesson learned, enthusiasm first, validation second 😉

On Milan’s question about the cleanup itself: so far we have not had a concrete need to implement this yet, simply because there has not been a real trigger from the business side. That said, we do expect this to become relevant in upcoming upgrades, so we are already preparing our projects to handle it properly. How have you approached this in your own projects?

Really appreciate you both taking the time to respond 👍

0

To response this discussion, you have to login first.