Telegram Bot API
🌐 English

sendRichMessageDraft

Category: Rich Messages · Bot API 10.3 · Official documentation

Streams a partial rich message — a 30-second preview (Bot API 10.1).

Returns: On success, returns True.

Parameters

ParameterTypeRequiredDescription
chat_idIntegerYesPrivate chat ID
message_thread_idIntegerOptionalTopic ID (for forums)
draft_idIntegerYesUnique draft ID (non-zero)
rich_messageInputRichMessageYesJSON InputRichMessage object — partial message to stream
can_stopBooleanOptionalShow a button to stop further drafts (Bot API 10.3)
keep_on_stopBooleanOptionalKeep the draft in the chat when the stop button is pressed (Bot API 10.3)

Parameter descriptions are concise summaries; see the official documentation for the full text.

Example request

curl

curl -s -X POST "https://api.telegram.org/bot$TOKEN/sendRichMessageDraft" \
  -H "Content-Type: application/json" \
  -d '{
  "chat_id": 123456789,
  "draft_id": 1,
  "rich_message": {
    "markdown": "**Hello** from a rich message"
  }
}'

Python

import requests

TOKEN = "123456789:AAEexampleTokenReplaceWithYours"
resp = requests.post(
    f"https://api.telegram.org/bot{TOKEN}/sendRichMessageDraft",
    json={
        "chat_id": 123456789,
        "draft_id": 1,
        "rich_message": {
            "markdown": "**Hello** from a rich message"
        }
    },
    timeout=30,
)
print(resp.json())

JavaScript

const TOKEN = "123456789:AAEexampleTokenReplaceWithYours";
const res = await fetch(`https://api.telegram.org/bot${TOKEN}/sendRichMessageDraft`, {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    "chat_id": 123456789,
    "draft_id": 1,
    "rich_message": {
      "markdown": "**Hello** from a rich message"
    }
  }),
});
console.log(await res.json());

Step-by-step guide: Telegram Bot API 10.0–10.3: Rich Messages, Ephemeral Messages, Guest Mode and More