Telegram - Send message with buttons or voice action

The Send message with buttons or voice action sends either a text message with an inline keyboard or a voice note to a chat in Telegram. Voice audio must be OGG/OPUS, MP3, or M4A format.

Input

Input fields vary based on your Message type selection. The following input fields are common to both options. Refer to the Telegram Bot API sendMessage and sendVoice documentation for more information on available input fields.

Input fieldDescription
Message typeSelect the type of message to send. Options are Text with buttons or Voice message. Defaults to Text with buttons.
Chat IDEnter the unique identifier for the target chat or the username of the target bot, supergroup, or channel.
Parse modeOptional. Select the mode to format the message text with bold, italic, or other styling. Options are Markdown, MarkdownV2, or HTML. Leave blank for plain text.
Disable notificationOptional. Select whether to send the message silently. If Yes, users receive a notification with no sound.
Protect contentOptional. Select whether to protect the message content from forwarding and saving.
Reply parametersOptional. Enter a description of the message this message is replying to.

VOICE CONTENT REQUIRED

Provide either a voice file (URL or file ID) or base64-encoded voice content for voice messages. The action fails if both are left blank.

Output

Output fields vary based on your Message type selection. The following output fields are common to both options. Refer to the Telegram Bot API Message documentation for more information on available output fields.

Output fieldDescription
Message IDThe message's unique identifier inside the chat.
ChatThe chat the message was sent to.
DateThe Unix timestamp the message was sent.

Last updated: