header
login

Incoming Message Trigger

The incoming message trigger starts a workflow every time a user sends a message to the bot. This is the most common trigger type.

Adding

  1. Right-click on an empty canvas area
  2. Select Triggers → New Trigger on Incoming Message
  3. Add a Step and functions inside it

How It Works

For each incoming message:

  1. The trigger activates
  2. The message text is saved to the {=message=} variable
  3. Sender data is available via {=tgData=}
  4. All functions in the trigger's steps execute in order

Available Data

Variable Description
{=message=} Message text
{=tgData.from.id=} User ID
{=tgData.from.first_name=} First name
{=tgData.from.username=} Username
{=tgData.chat.id=} Chat ID

Filtering Messages

Use the if function to handle different commands:

if "{=message=}" == "/start" → greeting
if "{=message=}" == "/help" → help
else → default response

Multiple Triggers

You can create multiple triggers in a single project — each with its own processing logic.