Telegram Send Audio

A guide to the Telegram Send Audio action for sending audio files to a Telegram chat.

The Telegram Send Audio Action allows you to send audio files to a specified Telegram chat or channel. This is useful for sharing voice notes, music, or other audio content.

Connection Setup

You will need a Telegram Bot and its API token.

  1. Create a new bot by talking to the BotFather on Telegram.

  2. The BotFather will provide you with an API token.

  3. In AgenticFlow, navigate to Settings > Connections and add a new Telegram Bot Connection, providing your API token.

Configuration

Input Parameters

Parameter
Type
Description

Connection

Connection

Select the Telegram Bot connection you created.

Chat ID

Text

The unique identifier for the target chat or channel (e.g., @channelusername or a chat ID).

Audio

Text

The audio file to send. You can provide a file path, an HTTP URL, or a file ID from Telegram's servers.

Caption

Text

An optional caption for the audio file (0-1024 characters).

Parse Mode

Select

Choose how to parse entities in the caption. Options are Markdown, MarkdownV2, or HTML.

Duration

Number

The duration of the audio in seconds.

Performer

Text

The performer of the audio.

Title

Text

The title of the audio.

Disable Notification

Boolean

If true, the message will be sent silently.

Protect Content

Boolean

If true, the content of the sent message will be protected from forwarding and saving.

Output Parameters

Parameter
Type
Description

message

Object

An object containing the details of the sent message, including message_id.

Example: Sending a Podcast Clip

This example demonstrates how to send a podcast clip to a Telegram channel.

  1. Get the Audio File: Use a File Input Action to select the audio file from your local machine.

  2. Configure the Telegram Send Audio Action:

    • Connection: Select your Telegram Bot connection.

    • Chat ID: @my_podcast_channel

    • Audio: {{file_input_action.file_path}}

    • Caption: Here's a clip from our latest episode!

    • Title: Episode 123 - The Future of AI

    • Performer: The AI Podcast

This workflow allows you to easily share audio content with your audience on Telegram.

Last updated

Was this helpful?