Send document or image
The Telegram Bot API Send Document or Image tool enables seamless sharing of documents and images directly to Telegram chats or channels. Designed for easy integration, it supports various file formats with customizable captions and message formatting options.
Features
- Supports sending documents and images in multiple formats including PDF, JPG, PNG, and MP4.
- Allows specifying target chat via chat ID or public username for versatile messaging.
- Enables adding captions to files with support for Markdown and HTML formatting.
- Supports silent message sending to avoid notifications if desired.
- Includes options for custom reply markups such as inline keyboards for interactive user engagement.
Benefits
- Streamlines file sharing within Telegram, improving communication efficiency.
- Enhances user experience with rich text captions and interactive buttons.
- Provides flexibility to target individual chats, groups, or public channels.
- Reduces notification fatigue with silent send option for non-disruptive messaging.
- Facilitates automation in workflows by integrating easily with existing tools and APIs.
Description
Sends a document or an image to your Telegram Desktop application. See the docs for more information
Parameters
9 parameters
| Name | Type | Description |
|---|---|---|
| chatIdrequired | string | Enter the unique identifier for the target chat (e.g. |
| caption | string | Enter the file caption. |
| filename | string | Enter a filename. |
| docrequired | string | File to send. Pass a file_id to send a file that exists on the Telegram servers, pass an HTTP URL for Telegram to get a file from the Internet, or pass the path to the file (e.g., |
| parse_mode | enum | Select MarkdownV2-style, HTML-style, or Markdown-style of the text if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in your bot's message. |
| contentType | enum | Select or enter the MIME type of data. |
| disable_notification | boolean | Choose if to send the message silently. iOS users will not receive a notification, Android users will receive a notification with no sound. |
| reply_to_message_id | string | Enter the ID of the original message. |
| reply_markup | string | Enter additional interface options that are a JSON-serialized object including an inline keyboard, a custom reply keyboard, instructions to remove the reply keyboard or instructions to force a reply from the user, e.g. |