Tool

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.

telegram_bot_api

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

NameTypeDescription
chatIdrequiredstring

Enter the unique identifier for the target chat (e.g. 1035597319) or username of the target public chat (in the format @channelusername or @supergroupusername). For example, if the group's public link is t.me/mygroup, the username is @mygroup.

captionstring

Enter the file caption.

filenamestring

Enter a filename.

docrequiredstring

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., /tmp/myFile.ext) to upload a new one using a file downloaded to /tmp. File must meet Telegram's requirements for MIME type and size.

parse_modeenum

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.

contentTypeenum

Select or enter the MIME type of data.

disable_notificationboolean

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_idstring

Enter the ID of the original message.

reply_markupstring

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. {"inline_keyboard":[[{"text":"Some button text 2","url":"https://botpress.org"}]]} or {"keyboard":[["Yes","No"],["Maybe"]]}. Note: keyboard cannot be used with channels. See the docs for more information.

Try Needle today

Streamline AI productivity at your company today

Join thousands of people who have transformed their workflows.

Agentic workflowsAutomations, meet AI agents
AI SearchAll your data, searchable
Chat widgetsDrop-in widget for your website
Developer APIMake your app talk to Needle
    Needle LogoNeedle
    Like many websites, we use cookies to enhance your experience, analyze site traffic and deliver personalized content while you are here. By clicking "Accept", you are giving us your consent to use cookies in this way. Read our more on our cookie policy .