Actions23
- Chat Actions
- Callback Actions
- File Actions
- Message Actions
Overview
The "Send Photo" operation of the Rahsaz Telegram node allows users to send photo messages to a specified chat or channel on Telegram. This node is useful for automating the distribution of images, such as product photos, event pictures, or any visual content, directly into Telegram chats or channels.
Typical use cases include:
- Sending promotional images to a marketing channel.
- Sharing user-uploaded photos automatically in a group.
- Broadcasting event photos to subscribers.
Users can provide the photo either by referencing an existing file on Telegram servers (using a file ID), by providing an HTTP URL for Telegram to fetch the image, or by uploading binary data directly through n8n.
Properties
Name | Meaning |
---|---|
Chat ID | Unique identifier for the target chat or username of the target channel (in the format @channelusername ). Specifies where the photo will be sent. |
Binary File | Boolean flag indicating whether the photo data should be taken from a binary field in the input data. |
Input Binary Field | The name of the binary property containing the photo data to upload when "Binary File" is true. Defaults to "data" . |
Photo | When not using binary data, this is the photo to send. Can be a Telegram file ID (to reuse an existing photo on Telegram servers) or an HTTP URL for Telegram to fetch the photo. |
Reply Markup | Additional interface options for the message. Options include: Force Reply , Inline Keyboard , None , Reply Keyboard , and Reply Keyboard Remove . |
Force Reply | If selected under Reply Markup, configures the message to force a reply interface for the user, optionally targeting specific users only. |
Inline Keyboard | Adds an inline keyboard next to the message with customizable rows and buttons. Buttons can have text labels and additional fields like callback data, URLs, payment buttons, or inline query switches. |
Reply Keyboard | Adds a custom reply keyboard with rows of buttons that send predefined replies or request contact/location information from the user. |
Reply Keyboard Options | Options for the reply keyboard such as resizing, one-time display, and selective visibility. |
Reply Keyboard Remove | Option to remove the custom keyboard from the client, optionally selectively. |
Additional Fields | Extra optional parameters including: |
- Caption | Caption text for the photo, up to 1024 characters. |
- Disable Notification | Whether to send the photo silently without notification sounds. |
- Parse Mode | How to parse the caption text. Options are Markdown (Legacy), MarkdownV2, or HTML. Default is HTML. |
- Reply To Message ID | If replying to a specific message, its ID. |
- Message Thread ID | Identifier of the forum topic (for topics in groups). |
- File Name | When uploading binary data, the filename to assign to the photo. Required if the binary data does not already have a filename. |
Output
The node outputs JSON data representing the response from the Telegram API after sending the photo. This typically includes details about the sent message such as message ID, chat info, date, and the photo metadata.
If the photo was uploaded as binary data, the node handles the binary stream internally but does not output binary data itself; the output is the Telegram API response JSON.
Dependencies
- Requires a valid Telegram Bot API key credential configured in n8n.
- Uses Telegram Bot API endpoints to send photos.
- Supports binary data input from previous nodes in the workflow.
Troubleshooting
- Missing File Name Error: When uploading binary data, if no filename is provided either in the binary property or via the "File Name" parameter, the node throws an error. Solution: Ensure the binary data has a filename or set it manually in the node's additional fields.
- Invalid Chat ID: If the chat ID or channel username is incorrect or inaccessible by the bot, the API call will fail. Verify the chat ID or username and bot permissions.
- Unsupported Photo Format: Telegram supports common image formats. Uploading unsupported formats may cause errors.
- API Rate Limits: Sending too many messages/photos in a short time may trigger Telegram rate limits. Implement delays or error handling accordingly.