N8N Tools Telegram icon

N8N Tools Telegram

Interact with Telegram Bot API

Overview

The "Send Message" operation of the "Messages" resource in this node allows users to send messages through the Telegram Bot API. It enables sending various types of content such as text messages, photos, videos, documents, locations, contacts, polls, and stickers to a specified Telegram chat.

This node is beneficial for automating communication workflows where messages need to be sent programmatically to Telegram users or groups. For example, it can be used to notify customers about order status updates, send alerts from monitoring systems, or broadcast announcements to community channels.

Practical examples:

  • Sending a welcome message to new users joining a Telegram group.
  • Automatically sharing daily reports or summaries via Telegram chats.
  • Dispatching event reminders or promotional content to subscribers.

Properties

Name Meaning
Chat ID The unique identifier for the target Telegram chat where the message will be sent.
Message Data JSON object containing the message details and content to send.

The Message Data property expects a JSON string representing the Telegram message payload. This can include fields like text, parse_mode, disable_web_page_preview, reply_markup, etc., according to the Telegram Bot API's sendMessage method specification.

Output

The node outputs an array of JSON objects, each corresponding to the result of sending a message for each input item processed. Each output JSON contains the response data returned by the Telegram Bot API for the sendMessage call, which typically includes information about the sent message such as message ID, date, chat details, and message content.

No binary data output is produced by this operation.

Dependencies

  • Requires an active Telegram Bot API token configured as credentials in n8n.
  • Uses an external validation service ("N8N Tools API") to verify subscription and API key before executing Telegram operations.
  • The node depends on the Telegram Bot API endpoints accessible over the internet.

Troubleshooting

  • Invalid subscription or API key error: If the node throws an error indicating invalid subscription or API key, verify that the API key credential is correctly set up and has the necessary permissions.
  • Malformed JSON in Message Data: Ensure that the JSON provided in the Message Data field is valid and conforms to the Telegram API requirements. Invalid JSON will cause parsing errors.
  • Chat ID issues: Confirm that the Chat ID corresponds to a valid Telegram chat accessible by the bot.
  • Unknown operation error: This node supports only predefined operations; ensure the operation parameter is set to "sendMessage" when using this summary.
  • Network connectivity problems may prevent the node from reaching Telegram servers or the validation API.

Links and References

Discussion