Python code org π—”βƒž+
24 subscribers
18 photos
2 videos
15 files
37 links
</> Python 🐍 </>
π™Όπšˆ π™Ώπšπ™Ύπ™Ήπ™΄π™²πšƒπš‚ | πšƒπ™΄π™²π™·π™½π™Ύ 𝙱𝙻𝙾𝙢

ADMIN: @Jamsh1db1k10
Download Telegram
Forwarded from BotNews
This media is not supported in your browser
VIEW IN TELEGRAM
Bot API 10.3

πŸ” Button Revolution
β€’ Buttons can now be placed right inside any rich message – with multiple native styles and custom alignment.
β€’ Out of the box, these buttons support callbacks, Mini Apps, Login URLs, copying text and more.
β€’ Bots can now mark inline buttons as disabled.

πŸ‘» Ephemeral Messages
β€’ Bots can now replace their messages with an ephemeral overlay, then edit it with rich content or newly uploaded media. This unlocks rich, personalized flows and responses running in a single message.

πŸ’ͺ Rich Messages
β€’ Bots can now attach documents to rich messages and more easily embed media – including previously uploaded files.
β€’ Rich Messages now support expandable quote blocks and compact tables.

πŸ¦€ AI Agents
β€’ Bots now support a native Stop button for streamed drafts and can optionally preserve partial responses.

β€’ And more, see the full changelog for details:

https://core.telegram.org/bots/api-changelog#august-24-2026
Please open Telegram to view this post
VIEW IN TELEGRAM
# Telegram Bot API 10.3 β€” Yangi funksiyalar uchun curl so'rovlari

> <TOKEN> o'rniga o'z bot tokeningizni, <CHAT_ID> o'rniga chat ID'ni qo'ying.

## 1. Rich Messages

### RichMessageButton bilan sendRichMessage
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendRichMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"rich_message": {
"blocks": [
{
"type": "buttons",
"buttons": [
{ "type": "button", "text": "Saytga o'\''tish", "url": "https://example.com" },
{ "type": "button", "text": "Callback", "callback_data": "action_1" }
]
}
]
}
}'

### RichBlockTable β€” is_compact bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendRichMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"rich_message": {
"blocks": [
{
"type": "table",
"is_compact": true,
"rows": [ ["Nomi", "Narxi"], ["Mahsulot A", "10 000 so'\''m"] ]
}
]
}
}'

### RichBlockExpandableBlockQuotation
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendRichMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"rich_message": {
"blocks": [
{
"type": "expandable_block_quotation",
"text": "Bu uzun iqtibos matni bo'\''lib, foydalanuvchi uni yig'\''ish yoki ochish imkoniga ega...",
"expanded": false
}
]
}
}'

### RichBlockDocument β€” fayl bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendRichMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"rich_message": {
"blocks": [
{
"type": "document",
"document": { "file_id": "BAADBAADrwADBREAAYag3z..." },
"caption": "Hisobot fayli"
}
]
}
}'

---

## 2. Ephemeral Messages

### sendMessage β€” ephemeral_message_parameters bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"text": "Bu vaqtinchalik xabar",
"ephemeral_message_parameters": {
"receiver_user_id": 987654321,
"callback_query_id": "unique_callback_id_123",
"replace_callback_query_message": true
}
}'

### sendPhoto β€” ephemeral xabar sifatida
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendPhoto" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"photo": "https://example.com/rasm.jpg",
"ephemeral_message_parameters": {
"receiver_user_id": 987654321
}
}'

### editEphemeralMessageMedia β€” yangi fayl yuklab (multipart)
curl -X POST "https://api.telegram.org/bot<TOKEN>/editEphemeralMessageMedia" \
-F "chat_id=<CHAT_ID>" \
-F "message_id=42" \
-F 'media={"type":"photo","media":"attach://new_photo.jpg"}' \
-F "new_photo.jpg=@/local/path/rasm.jpg"

### editEphemeralMessageCaption β€” show_caption_above_media bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/editEphemeralMessageCaption" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"message_id": 42,
"caption": "Yangi tavsif",
"show_caption_above_media": true
}'

### editEphemeralMessageText β€” rich_message bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/editEphemeralMessageText" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"message_id": 42,
"rich_message": {
"blocks": [ { "type": "text", "text": "Yangilangan matn" } ]
}
}'

---

## 3. can_send_welcome_messages

### promoteChatMember
curl -X POST "https://api.telegram.org/bot<TOKEN>/promoteChatMember" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"user_id": 987654321,
"can_send_welcome_messages": true
}'
### getChatMember β€” natijada can_send_welcome_messages ko'rinadi
curl -X GET "https://api.telegram.org/bot<TOKEN>/getChatMember?chat_id=<CHAT_ID>&user_id=987654321"

---

## 4. Reply Markup

### DisabledButton β€” disabled maydoni bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"text": "Tanlovni belgilang",
"reply_markup": {
"inline_keyboard": [
[
{ "text": "Faol tugma", "callback_data": "active" },
{ "text": "O'\''chirilgan", "callback_data": "inactive", "disabled": true }
]
]
}
}'

### force_reply β€” Inline klaviaturada
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"text": "Savolga javob bering",
"reply_markup": {
"inline_keyboard": [[ { "text": "Javob berish", "callback_data": "reply_1" } ]],
"force_reply": true
}
}'

### force_reply β€” Reply klaviaturada
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"text": "Tanlang",
"reply_markup": {
"keyboard": [[ { "text": "Ha" }, { "text": "Yo'\''q" } ]],
"resize_keyboard": true,
"force_reply": true
}
}'

---

## 5. Umumiy funksiyalar

### sendMessageDraft β€” can_stop va keep_on_stop bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendMessageDraft" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"text": "Yozilmoqda...",
"can_stop": true,
"keep_on_stop": true
}'

### sendRichMessageDraft β€” can_stop va keep_on_stop bilan
curl -X POST "https://api.telegram.org/bot<TOKEN>/sendRichMessageDraft" \
-H "Content-Type: application/json" \
-d '{
"chat_id": <CHAT_ID>,
"rich_message": { "blocks": [ { "type": "text", "text": "Tayyorlanmoqda..." } ] },
"can_stop": true,
"keep_on_stop": false
}'

### getUpdates β€” MessageGenerationStopped va CommunityChatJoined kabi yangilanishlarni olish
curl -X GET "https://api.telegram.org/bot<TOKEN>/getUpdates"

Javobda quyidagi kabi maydonlar keladi:
{
"update_id": 100000001,
"stopped_message_generation": {
"chat": { "id": <CHAT_ID>, "type": "private" },
"message_id": 42
}
}

```json
{
"message_id": 55,
"chat": { "id": <CHAT_ID>, "type": "supergroup" },
"community_chat_joined": {
"chat": { "id": -1009876543210, "type": "supergroup" }
}
}

### getUniqueGiftInfo β€” text, entities, is_private bilan

bash
curl -X GET "https://api.telegram.org/bot<TOKEN>/getBusinessConnection?business_connection_id=<CONNECTION_ID>"
Javobdagi `UniqueGiftInfo` obyekti:

json
{
"gift": { "id": "gift_001" },
"origin": "upgrade",
"text": "Tabriklaymiz!",
"entities": [ { "type": "bold", "offset": 0, "length": 11 } ],
"is_private": true
}
`
Forwarded from οΈβ‹–/β‹—
Please open Telegram to view this post
VIEW IN TELEGRAM
Forwarded from οΈβ‹–/β‹—
Please open Telegram to view this post
VIEW IN TELEGRAM
Kimdadir biror starts yoki mine bot bormi? Avto qilishga harakat qilamiz πŸ€–βœ¨
Agar sizga 100 ta stars evaziga, koΚ»chirib boΚ»lmaydigan aΚΌzo chatlaridagi barcha maΚΌlumotlarni boshqa chatga koΚ»chirish imkonini beruvchi bot kodini taqdim etsam, uni qabul qilishga tayyormisiz? πŸ€”
Hammaga salom πŸ‘‹
Oramizda Satga qiziqadiganlar bormi? πŸ€”
πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡
https://t.me/grantdasturbot?start=NTEzOA
πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†πŸ‘†
1200+ olish uchun bu botni maslahat beraman πŸ“ˆ Foydali βœ…
Kimda biror bot bor? πŸ€–
10-15 kun host qilib beraman πŸ“…
Pythonda boΚ»lsa πŸ’»
Hammaga yaxshi kayfiyat πŸ˜„
❀‍πŸ”₯1❀1
Ertaga maktab... 🏫
🫣🫠
@uzb_228 bugun tugulgan kuniz ekan tabriklaymiz uzoq umur korin
❀‍πŸ”₯2
Maktab qalay boʻldi? 😁