Telegram

Sends data to Telegram

Overview

This node allows sending various types of messages and media to Telegram chats. Specifically, the 'Send Document' operation enables users to send documents to a specified Telegram chat either by uploading a file from binary data or by referencing an existing file on Telegram servers or an HTTP URL. It supports additional options like captions, reply markups (inline keyboards, reply keyboards, force replies), and other Telegram-specific message settings. This node is useful for automating document sharing in Telegram groups, channels, or direct messages, such as sending reports, PDFs, or other files automatically triggered by workflows.

Use Case Examples

  1. Automatically send a PDF report to a Telegram group when a new report is generated.
  2. Send a document stored in binary form from a previous workflow step to a Telegram user.
  3. Share a document via a Telegram channel using a URL to the file hosted online.

Properties

Name Meaning
Chat ID Unique identifier for the target chat or username of the target channel where the document will be sent.
Binary File Indicates whether the document to send should be taken from a binary field in the input data.
Input Binary Field The name of the binary property containing the file data to upload when Binary File is true.
Document The document to send when Binary File is false. Can be a Telegram file_id or an HTTP URL.
Reply Markup Additional interface options for the message, such as inline keyboard, reply keyboard, force reply, or none.
Force Reply Options to configure force reply behavior, including whether to show the reply interface and whether to restrict it to specific users.
Inline Keyboard Defines rows and buttons for an inline keyboard attached to the message.
Reply Keyboard Defines rows and buttons for a custom reply keyboard attached to the message.
Reply Keyboard Options Options to customize the reply keyboard behavior, such as resizing, one-time use, and selective display.
Reply Keyboard Remove Options to remove the custom keyboard and selectively force reply from specific users.
Additional Fields Additional optional parameters for the message, such as caption, disable notification, parse mode, file name, thumbnail, and custom JSON fields for advanced Telegram API options.
Wait for Response Whether to wait for a response from the user after sending the message.
Timeout Timeout in seconds to wait for a user response if 'Wait for Response' is enabled.

Output

JSON

  • json - The JSON response from the Telegram API for the sent document message.

Dependencies

  • Telegram API
  • An API key credential for Telegram authentication

Troubleshooting

  • Ensure the chat ID is correct and the bot has permission to send messages to the chat.
  • If sending a binary file, make sure the binary property contains valid file data and the file name is set either in the binary metadata or in the 'File Name' additional field.
  • For HTTP URLs or file IDs, verify the URL or file ID is accessible and valid on Telegram servers.
  • If the node throws errors about missing parameters, check that all required fields like 'Chat ID' and 'Document' or binary data are properly set.

Links

Discussion