with one click
telegram
Send notifications and messages via Telegram bot API
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Send notifications and messages via Telegram bot API
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
Drive the OpenWork dev renderer with Chrome MCP and verify workspace UI flows. Triggers when user mentions: - "use Chrome MCP with OpenWork" - "hook up to pnpm dev renderer" - "add an OpenWork workspace through the UI"
Create a PR with structured evidence: build verification, UI screenshots uploaded to an ephemeral host, API test results, and a verification comment. No screenshots committed to the repo. Triggers when user mentions: - "create a pr" - "make a pr" - "open a pr" - "push and pr"
Boot up the Den dev stack and the OpenWork desktop app locally, then test common flows like sign-in, dashboard, and telemetry. Triggers when user mentions: - "test den" - "test the app locally" - "boot up den" - "den dev flow" - "test sign in"
Generate or update the internal OpenWork release changelog tracker as plain markdown release sections. Triggers when user mentions: - "generate changelog markdown" - "track this release" - "add a changelog entry"
CUPID app architecture guidance for apps/app/src/app/**
Manage Vercel environment variables for OpenWork projects from the CLI, including linking the local app directory first. Triggers when user mentions: - "add a vercel env var" - "set a vercel env var" - "vercel environment variable"
| name | telegram |
| description | Send notifications and messages via Telegram bot API |
IMPORTANT: Before using any Telegram commands, source the local .env file:
source .skill.config
Credentials are stored in .skill.config (gitignored):
TELEGRAM_BOT_TOKEN=...
TELEGRAM_CHAT_ID=... # Default chat (legacy, still works)
Chat aliases are stored in telegram-chats.json (gitignored):
{
"chats": {
"default": { "id": "123456789", "name": "Personal", "description": "Default notifications" },
"alerts": { "id": "-100987654321", "name": "Alerts", "description": "Critical alerts" },
"house": { "id": "-4972420459", "name": "House Common", "description": "House group" }
}
}
jq -r '.chats.house.id' .opencode/skill/telegram/telegram-chats.json
jq -r '.chats | to_entries[] | "\(.key): \(.value.name) (\(.value.id))"' .opencode/skill/telegram/telegram-chats.json
source .skill.config && curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$TELEGRAM_CHAT_ID" \
-d "text=Hello from OpenCode!"
source .skill.config && CHAT_ID=$(jq -r '.chats.house.id' .opencode/skill/telegram/telegram-chats.json) && \
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$CHAT_ID" \
-d "text=Hello House!"
source .skill.config && for chat in default house; do
CHAT_ID=$(jq -r ".chats.$chat.id" .opencode/skill/telegram/telegram-chats.json)
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$CHAT_ID" \
-d "text=Broadcast message!" &
done
wait
source .skill.config && curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$TELEGRAM_CHAT_ID" \
-d "parse_mode=Markdown" \
-d "text=*Bold* and _italic_ and \`code\`"
source .skill.config && curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$TELEGRAM_CHAT_ID" \
-d "parse_mode=HTML" \
-d "text=<b>Bold</b> and <i>italic</i> and <code>code</code>"
source .skill.config && curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$TELEGRAM_CHAT_ID" \
-d "parse_mode=Markdown" \
-d "text=Check out [this deal](https://facebook.com/marketplace/item/123)"
source .skill.config && curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$TELEGRAM_CHAT_ID" \
-d "parse_mode=Markdown" \
--data-urlencode "text=*New Deals Found*
1. \$50 - Vintage Poster [View](link1)
2. \$30 - Movie Poster [View](link2)"
source .skill.config && curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getMe" | jq
source .skill.config && echo "Token: ${TELEGRAM_BOT_TOKEN:0:10}... Chat: $TELEGRAM_CHAT_ID"
jq '.chats' .opencode/skill/telegram/telegram-chats.json
\ before _, *, `, [ if they're literal--data-urlencode for messages with special chars- (group/channel)-100 for supergroups/newbotbot, e.g., "myopencode_bot")curl -s "https://api.telegram.org/bot<YOUR_TOKEN>/getUpdates" | jq '.result[0].message.chat.id'
curl -s "https://api.telegram.org/bot<YOUR_TOKEN>/getUpdates" | jq '.result[] | select(.message.chat.type != "private") | {title: .message.chat.title, id: .message.chat.id}'
Add to .skill.config:
TELEGRAM_BOT_TOKEN=your_token_here
TELEGRAM_CHAT_ID=your_default_chat_id_here
cp .opencode/skill/telegram/telegram-chats.example.json .opencode/skill/telegram/telegram-chats.json
Then edit telegram-chats.json to add your chats:
{
"chats": {
"default": {
"id": "YOUR_PERSONAL_CHAT_ID",
"name": "Personal",
"description": "My personal notifications"
},
"alerts": {
"id": "GROUP_CHAT_ID",
"name": "Alerts Group",
"description": "System alerts"
}
}
}
# Test default
source .skill.config && curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$TELEGRAM_CHAT_ID" \
-d "text=OpenCode connected!"
# Test named chat
source .skill.config && CHAT_ID=$(jq -r '.chats.house.id' .opencode/skill/telegram/telegram-chats.json) && \
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$CHAT_ID" \
-d "text=House chat connected!"
source .skill.config && curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates" | jq '.result[-1].message.chat'
telegram-chats.jsonsource .skill.config && curl -s "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/getUpdates" | \
jq '[.result[].message.chat] | unique_by(.id) | .[] | {id, title: (.title // .first_name), type}'
For complex scripts, define a helper:
telegram_send() {
local chat_alias="${1:-default}"
local message="$2"
local parse_mode="${3:-Markdown}"
source .skill.config
local chat_id=$(jq -r ".chats.$chat_alias.id" .opencode/skill/telegram/telegram-chats.json)
curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \
-d "chat_id=$chat_id" \
-d "parse_mode=$parse_mode" \
--data-urlencode "text=$message"
}
# Usage:
telegram_send "house" "Hello from the house chat!"
telegram_send "bargains" "*New deal found!*" "Markdown"