Skip to main content

Send Telegram Message

Send a message to a particular chat that a Telegram Bot has access to. The activity currently allows to send text-only messages. Feel free to contact us if you want a particular API feature supported in an upcoming version.

A bot needs to be created and the token obtained from Telegram is required to successfully send a message. See the getting started guide and further documentation.

Usage​

Always uses the next action in the outgoing edge. If an error occurs the unrecoverable error is used, which may occur if e.g. no internet connection is available to contact the chat endpoint.

Variables​

The telegram.message_text variable contains the text to send. A maximum of 4096 characters is allowed by Telegram, which is a lot for a chat message. If this limit is exceeded Cocosplate will create up to 3 separate messages split at the last whitespace available to fit within the maximum allowed length.

The telegram.api_token and telegram.chat_id variables are set automatically when an incoming chat request is handled by the Incoming Chat Event.

This action is usually used in combination with receiving a chat request.