Actions23
- Chat Actions
- Callback Actions
- File Actions
- Message Actions
Overview
The "Send Media Group" operation of the Message resource in this Telegram node allows sending a group (album) of photos and/or videos to a specified chat. This is useful when you want to send multiple media items as a single message album, which Telegram displays as a cohesive group rather than separate messages.
Common scenarios include:
- Sharing an event's photo and video highlights together.
- Sending multiple product images or promotional videos in one go.
- Creating media albums for storytelling or updates.
For example, you can send a batch of photos from a recent trip or a set of short videos showcasing different features of a product.
Properties
Name | Meaning |
---|---|
Chat ID | Unique identifier for the target chat or username of the target channel (e.g., @channelusername ). Specifies where the media group will be sent. |
Media | Collection of media items to send. Each item includes: - Type: Photo or Video. - Media File: A file ID (for existing Telegram files) or an HTTP URL. - Additional Fields: • Caption text (0-1024 chars) • Parse Mode (Markdown, MarkdownV2, HTML) for caption formatting. |
Additional Fields | Optional parameters for the entire media group message, such as disabling notifications, replying to a specific message, setting message thread ID, etc. |
Details on Media Items
Each media item supports:
- Type: Choose between "Photo" or "Video".
- Media File: The actual media content reference (file ID or URL).
- Caption: Text description for the media.
- Parse Mode: How to parse the caption text (Markdown legacy, MarkdownV2, or HTML).
Output
The node outputs an array of JSON objects representing the Telegram API response for the sent media group message. Each output item corresponds to one input item processed.
The json
field contains the full Telegram API response, typically including details about the sent message(s), such as message IDs, chat info, and media metadata.
If the operation involves downloading files (not applicable here), binary data would be included, but for sending media groups, the output is JSON only.
Dependencies
- Requires a valid Telegram Bot API key credential configured in n8n.
- Internet access to Telegram servers.
- For media files referenced by URLs, those URLs must be accessible by Telegram servers.
- No additional external dependencies beyond the Telegram API.
Troubleshooting
- Missing or invalid Chat ID: Ensure the chat ID or channel username is correct and the bot has permission to send messages there.
- Invalid media references: If using file IDs, ensure they exist on Telegram servers; if using URLs, verify they are publicly accessible.
- Caption length exceeded: Captions must be 0-1024 characters; longer captions will cause errors.
- Unsupported media types: Only photos and videos are supported in media groups.
- API errors: Check that the bot token is valid and has necessary permissions.
- File name missing for binary uploads: When uploading binary data (not typical for media groups), a filename must be provided.