Creating Messages
Creating Bot Messages
Messages are the content your bot sends to users. Create rich, interactive messages with buttons and media.
Message Components
Text Content
The main message text. Supports:
- HTML formatting - <b>, <i>, <code>, <a>
- Template variables - Dynamic content like {{user.name}}
- Spintax - Random variations like {Hi|Hello|Hey}
Media Attachments
Add photos, videos, documents, or other media to your messages. Configure how multiple media items are handled.
Reply Markup
Add interactive buttons:
- Inline Keyboard - Buttons below the message with callback or URL actions
- Reply Keyboard - Custom keyboard replacing the default one
Using Templates
Messages can inherit content from Message Templates. This allows you to:
- Reuse common content across multiple messages
- Update content in one place
- Override specific fields when needed
Template Variables
{{ bot.username }} - Bot username
{{ user.name }} - User's name
{{ user.username }} - User's Telegram username
{{ s.snippet_key }} - Snippet value
{{ message.text }} - Original message text
Was this article helpful? Thank you for your feedback!