Message format through the API
To send or edit a message through the API, pass its text in content and its format in content_format. The format describes the source text, not the recipient's platform. Senler prepares the message for the selected channel.
Choosing a format
plain_textpreserves characters literally. For example,**Important**remains text with asterisks.markdownuses markup for formatting:**Important**becomes bold on platforms that support it.
Sending an operator message without content_format uses plain text. Editing without this field preserves the original message format. Set the format explicitly when changing how the text is formatted.
Sending a message
Use POST /api/dialogs/DIALOG_ID/send. Authorization is described in the API section. Example JSON body:
{
"content": "**Your order is ready**\n\n[View order](https://example.com/orders/123)",
"content_format": "markdown"
}
This request sends a message to a customer. Use a dialog intended for testing when checking your integration.
To edit, use PATCH /api/dialogs/DIALOG_ID/events/EVENT_ID with the same fields. Editing is subject to message editing restrictions.
A successful API response does not guarantee delivery to an external platform. In particular, 202 when editing means the local change was accepted and platform synchronization runs asynchronously. Check the final message status.
Supported markup
Markdown supports bold, italic, strikethrough, links, headings, lists, quotes, tables, inline code, and code blocks. It also supports:
<u>underlined text</u>;<spoiler>hidden text</spoiler>.
These are special formatting markers, not permission to insert arbitrary HTML. For example, <b>text</b> does not replace Markdown **text**. In plain_text mode, even <u> and <spoiler> remain literal text.
Do not send ready-made Telegram HTML or MarkdownV2 instead of source Markdown. Send pictures as attachments: the Markdown image link  does not itself upload a file to an external platform.
Formatting in different channels
- The cabinet and widget display the saved message format, including tables and revealable hidden text.
- Telegram receives supported formatting, including underline and hidden text. Tables are sent as text rows, not interactive tables.
- MAX receives supported formatting, but hidden text remains visible.
- Discord receives the platform's own markup. If a combination of styles cannot be represented without distorting the text, some formatting is simplified.
- Email receives an HTML message with formatting and tables; hidden text remains visible.
- VK, Avito, and StreamVi receive plain text. If a link label differs from its URL, the URL is appended in parentheses.
Do not use hidden text for secrets: it does not restrict access to the content, and some channels do not hide it at all. Message and attachment-caption length are limited by the platform; long VK text is sent in multiple parts.