Back to Templates
This Telegram workflow batches rapid-fire messages from the same user into one prompt (20–30s debounce), then sends a single AI reply.
It uses two Google Sheets:
date | user_id | message) — queues incoming messages.user_id | is_waiting | last_updated) — debounces per user.Flow per message:
user_id. If empty, synthesize { is_waiting:false }.last_updated is older than 30s, oris_waiting is falseis_waiting=true, update last_updated, Wait (e.g., 30s).last_updated (extend the window) — we do not start another wait.Copy/paste:
{{ new Date(Date.now() - 30000).toISOString() }}Supports text and voice (voice via Whisper). Works reliably on Telegram once the webhook is registered and Sheets are shared with the service account.