Add support for auto-closing tickets after customer inactivity (time-based automation for messengers)

In messenger-based support (e.g. Telegram), tickets often originate from chat groups or channels and may remain open indefinitely if the customer stops responding. Zammad currently lacks a native mechanism to automatically close such tickets after a period of inactivity (e.g. 24h, 3d).

This creates clutter, increases workload for agents, and makes queue management harder — especially when working with Telegram chats where “new topics” are not clearly separated unless previous ones are manually closed.

Proposed solution:

Allow defining a time-based automation that:

  • Checks if there was no customer reply for N hours/days;
  • Optionally checks current ticket state (e.g. waiting for customer);
  • Then changes ticket state to closed or a custom one.

This can be a new condition in “Automation → Scheduler”, similar to how OTRS or Freshdesk handle it.

Use case example:

  • Telegram ticket opened at 10:00.
  • Agent replies at 10:05, waiting for customer.
  • No response after 48h → ticket auto-closed.
  • A new message from customer later → new ticket is created (Zammad handles that).

Why it matters:

  • In chat-first support, customers rarely close tickets themselves.
  • Helps keep Telegram-based tickets clean and atomic.
  • Reduces manual workload and human error.
  • Prevents bloated queues with stale, inactive tickets.