Trigger Receive Telegram
Description
Section titled “Description”The telegramReceive module is a trigger that initiates the workflow when a message is received on a Telegram bot. It processes multiple content types: text, commands, photos, voice, documents, audio, video, location, contacts, stickers, polls, venues, and callback queries (inline buttons). For each content type, it extracts the relevant information and structures it uniformly with type, chatId, content, from, chat, and metadata fields. It also detects forwarded messages, replies, and text entities.
Configuration
Section titled “Configuration”Parameters
Section titled “Parameters”| Parameter | Type | Required | Description |
|---|---|---|---|
| token | text | Yes | Telegram bot token (botToken). Obtained from BotFather. |
| url_webhook | webhook_generator | No | Automatically generated webhook URL to receive Telegram updates. |
Output
Section titled “Output”{ "nextModule": "siguiente_modulo", "data": { "type": "text", "chatId": 123456789, "from": { "id": 123456789, "first_name": "Juan", "language_code": "es" }, "botToken": "123456:ABCdefGHIjklMNO", "date": "2026-03-23T10:00:00.000Z", "content": "Hola, necesito ayuda", "chat": { "id": 123456789, "type": "private", "first_name": "Juan" }, "metadata": { "message_id": 42, "update_id": 987654321, "is_edited": false } }}Usage Example
Section titled “Usage Example”Basic case
Section titled “Basic case”{ "label": "Trigger Receive Telegram", "token": "123456789:ABCdefGHIjklMNOpqrSTUvwxYZ", "url_webhook": {}}API Used
Section titled “API Used”Telegram Bot API - Webhook updates. The webhook URL is registered at https://api.telegram.org/bot{token}/setWebhook.
- Supported message types: text, command, photo, voice, document, audio, video, location, venue, contact, sticker, poll, callback_query.
- For commands (messages starting with
/), the type is set tocommandand the command and its parameters are extracted inmetadata.commandandmetadata.command_params. - For photos, the highest resolution version is automatically selected.
- The
contentfield contains the main content depending on the type: message text, file_id for files, coordinates for locations, etc. - The
botTokenis included in the output so that subsequent nodes can send responses to the user. - Supports callback queries (inline buttons), returning the
callback_query_idin metadata to confirm the interaction. - Forwarded message, reply, and entity metadata is automatically added when present.
Related Nodes
Section titled “Related Nodes”- telegramVoiceToText (Telegram audio transcription)
- Webhook (generic trigger)
- decision (to evaluate message type)