setMyShortDescription
Đặt mô tả ngắn cho bot.
Giá trị trả về: Nếu thành công, trả về True.
Tham số
| Tham số | Kiểu | Bắt buộc | Mô tả |
|---|---|---|---|
short_description | String | Tùy chọn | Mô tả ngắn mới (chuỗi rỗng = xóa) |
language_code | String | Tùy chọn | Mã ngôn ngữ (thẻ IETF) |
Ví dụ request
curl
curl -s "https://api.telegram.org/bot$TOKEN/setMyShortDescription"
Python
import requests
TOKEN = "123456789:AAEexampleTokenReplaceWithYours"
resp = requests.get(f"https://api.telegram.org/bot{TOKEN}/setMyShortDescription", timeout=30)
print(resp.json())
JavaScript
const TOKEN = "123456789:AAEexampleTokenReplaceWithYours";
const res = await fetch(`https://api.telegram.org/bot${TOKEN}/setMyShortDescription`);
console.log(await res.json());
Hướng dẫn từng bước: Cách tạo bot Telegram từ A đến Z: BotFather, token và tin nhắn đầu tiên
Phương thức liên quan
getMeTrả về thông tin của bot.getMyCommandsTrả về danh sách lệnh hiện tại của bot.setMyCommandsĐặt danh sách lệnh của bot.deleteMyCommandsXóa các lệnh của bot.getMyNameTrả về tên của bot.setMyNameĐặt tên cho bot.getMyDescriptionTrả về mô tả của bot.setMyDescriptionĐặt mô tả cho bot.getMyShortDescriptionTrả về mô tả ngắn của bot.setMyProfilePhotoĐặt ảnh đại diện cho bot.removeMyProfilePhotoXóa ảnh đại diện của bot.getUserProfilePhotosTrả về ảnh đại diện của người dùng.