Documentation

Guides and help for BotStat services
BotStat API · BotManager

Create a mailing

Updated 01.12.2026 2 min read
POST /create_bm_post/{token}/ Create a mailing over the bot's database in @BotManRobot. The mailing is queued right away.
token
Bot token from @BotFather - of the same bot as bot_id

Request body (JSON)

FieldRequiredWhat it is
bot_idyesBot ID in BotManager (UUID) - the "ID" line in the bot card in @BotManRobot, "My bots" section
message_textnoPost text, Telegram HTML markup
imagenoImage: an https link or a file_id received by this same bot. The text becomes the caption
stickernoSticker: file_id. With a sticker the text is not sent
board_textnoButtons under the post, format below
speedno, 60Messages per second, up to 1000
speed_fixedno, falsetrue - keep the set speed, do not adjust it automatically

Buttons

Each line is a row of buttons, buttons in a row are separated by |, name and value by -. If the name contains a hyphen, put spaces around the separator: Name - value.

Website - https://example.com
Link button
Open - !!!!https://example.com/app
Mini app (WebApp)
Share - !!text
Choose a chat for an inline query
Search - !!!text
Inline query in the same chat

Button color: add !red, !blue or !green (short !r, !b, !g) to its name, for example: Buy !green - https://example.com.

Request example

bash
curl -X POST https://api.botstat.io/create_bm_post/BOT_TOKEN/ \
  -H "Content-Type: application/json" \
  -d '{"bot_id": "BOT_UUID", "message_text": "<b>Hi!</b> A new feature is live in the bot", "board_text": "Open - https://t.me/examplebot", "speed": 60}'
Keep the token secretThe token is part of the request URL: do not publish such links and do not send the request from users' browsers - only from your server.

Response

json
{
  "answer": true,
  "desc": "success"
}
ResponseWhen
{"answer": true, "desc": "success"}Mailing created
{"answer": false, "desc": "no have bot"}No bot with this bot_id in BotManager
{"ok": false, "result": {"error_code": "INVALID_TOKEN", …}} - HTTP 401The token is wrong or belongs to another bot
{"ok": false, "result": {"error_code": "MISSING_PARAMETERS", …}} - HTTP 422bot_id is missing
{"ok": false, "result": {"error_code": "INVALID_PARAMETERS", …}} - HTTP 422bot_id is not a UUID or a field has the wrong type
{"ok": false, "result": {"error_code": "RATE_LIMITED", …}} - HTTP 429More than 5 requests per second from one address. Retry in a second
{"ok": false, "result": {"error_code": "INTERNAL_ERROR", …}} - HTTP 500The mailing could not be created, for example the bot has no database. Retry later
Was this article helpful? Didn't find the answer? Contact support