
Telegram Bot
- 18 installs
- 638 repo stars
- Updated March 7, 2026
- sundial-org/awesome-openclaw-skills
Helps with ai & agent building tasks during AI-assisted development.
About
telegram-bot is a Claude Code skill for ai & agent building. It helps solo builders move faster with AI-assisted coding.
- telegram-bot
- AI & Agent Building
- AI-coding skill
Telegram Bot by the numbers
- 18 all-time installs (skills.sh)
- Ranked #10,730 of 16,546 AI & Agent Building skills by installs in the Skillselion catalog
- Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/sundial-org/awesome-openclaw-skills --skill telegram-botAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 18 |
|---|---|
| repo stars | ★ 638 |
| Last updated | March 7, 2026 |
| Repository | sundial-org/awesome-openclaw-skills ↗ |
What it does
Helps with ai & agent building tasks during AI-assisted development.
Files
Telegram Bot Builder Skill
Build and manage Telegram bots directly from Clawdbot.
Setup
1. Open Telegram and message @BotFather 2. Send /newbot and follow the prompts to create your bot 3. Copy the bot token (looks like 123456789:ABCdefGHIjklMNOpqrsTUVwxyz) 4. Set environment variable:
export TELEGRAM_BOT_TOKEN="your-bot-token"API Base URL
All requests go to:
https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/METHOD_NAMEUsage
Bot Information
Get bot info
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getMe" | jqGet bot commands
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getMyCommands" | jqSet bot commands
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/setMyCommands" \
-H "Content-Type: application/json" \
-d '{
"commands": [
{"command": "start", "description": "Start the bot"},
{"command": "help", "description": "Show help message"},
{"command": "settings", "description": "Bot settings"}
]
}' | jqSending Messages
Send text message
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"text": "Hello from Clawdbot!",
"parse_mode": "HTML"
}' | jqSend message with inline keyboard
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"text": "Choose an option:",
"reply_markup": {
"inline_keyboard": [
[{"text": "Option 1", "callback_data": "opt1"}, {"text": "Option 2", "callback_data": "opt2"}],
[{"text": "Visit Website", "url": "https://example.com"}]
]
}
}' | jqSend message with reply keyboard
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"text": "Choose from keyboard:",
"reply_markup": {
"keyboard": [
[{"text": "Button 1"}, {"text": "Button 2"}],
[{"text": "Send Location", "request_location": true}]
],
"resize_keyboard": true,
"one_time_keyboard": true
}
}' | jqSend photo
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendPhoto" \
-F "chat_id=CHAT_ID" \
-F "photo=@/path/to/image.jpg" \
-F "caption=Photo caption here" | jqSend photo by URL
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendPhoto" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"photo": "https://example.com/image.jpg",
"caption": "Image from URL"
}' | jqSend document
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendDocument" \
-F "chat_id=CHAT_ID" \
-F "document=@/path/to/file.pdf" \
-F "caption=Here is your document" | jqSend location
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendLocation" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"latitude": 40.7128,
"longitude": -74.0060
}' | jqGetting Updates
Get updates (polling)
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates" | jqGet updates with offset (mark as read)
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates?offset=UPDATE_ID" | jqGet updates with timeout (long polling)
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates?timeout=30" | jqWebhooks
Set webhook
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/setWebhook" \
-H "Content-Type: application/json" \
-d '{
"url": "https://your-server.com/webhook",
"allowed_updates": ["message", "callback_query"]
}' | jqGet webhook info
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getWebhookInfo" | jqDelete webhook
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/deleteWebhook" | jqChat Management
Get chat info
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getChat?chat_id=CHAT_ID" | jqGet chat member count
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getChatMemberCount?chat_id=CHAT_ID" | jqGet chat administrators
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getChatAdministrators?chat_id=CHAT_ID" | jqBan user from chat
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/banChatMember" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"user_id": USER_ID
}' | jqUnban user
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/unbanChatMember" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"user_id": USER_ID,
"only_if_banned": true
}' | jqMessage Management
Edit message text
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/editMessageText" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"message_id": MESSAGE_ID,
"text": "Updated message text"
}' | jqDelete message
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/deleteMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"message_id": MESSAGE_ID
}' | jqPin message
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/pinChatMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "CHAT_ID",
"message_id": MESSAGE_ID
}' | jqForward message
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/forwardMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "TARGET_CHAT_ID",
"from_chat_id": "SOURCE_CHAT_ID",
"message_id": MESSAGE_ID
}' | jqCallback Queries
Answer callback query
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/answerCallbackQuery" \
-H "Content-Type: application/json" \
-d '{
"callback_query_id": "CALLBACK_QUERY_ID",
"text": "Button clicked!",
"show_alert": false
}' | jqNotes
- Chat ID: Can be positive (user) or negative (group/channel). Get it from updates or use @userinfobot
- Parse modes:
HTML,Markdown,MarkdownV2 - Rate limits: ~30 messages/second to different chats, 1 message/second to same chat
- File limits: Photos up to 10MB, documents up to 50MB
- Bot permissions: Bots can't message users first - user must /start the bot
HTML Formatting
<b>bold</b>
<i>italic</i>
<u>underline</u>
<s>strikethrough</s>
<code>inline code</code>
<pre>code block</pre>
<a href="https://example.com">link</a>
<tg-spoiler>spoiler</tg-spoiler>Examples
Simple echo bot (bash script)
#!/bin/bash
OFFSET=0
while true; do
UPDATES=$(curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates?offset=$OFFSET&timeout=30")
for UPDATE in $(echo "$UPDATES" | jq -c '.result[]'); do
UPDATE_ID=$(echo "$UPDATE" | jq '.update_id')
CHAT_ID=$(echo "$UPDATE" | jq '.message.chat.id')
TEXT=$(echo "$UPDATE" | jq -r '.message.text')
if [ "$TEXT" != "null" ]; then
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-H "Content-Type: application/json" \
-d "{\"chat_id\": $CHAT_ID, \"text\": \"You said: $TEXT\"}"
fi
OFFSET=$((UPDATE_ID + 1))
done
doneGet your chat ID
# 1. Send a message to your bot
# 2. Run this to see your chat ID:
curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates" | jq '.result[-1].message.chat.id'Send to channel
# Use @channelname or channel ID (starts with -100)
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-H "Content-Type: application/json" \
-d '{
"chat_id": "@your_channel_name",
"text": "Channel announcement!"
}' | jqUseful Resources
Related skills
AI & Agent Buildingagents