Telegram Bot API - Integracao Profissional workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

MITAuto-check passedBackend & APIs

Install Telegram

skills CLI
$ npx skills add diegosouzapw/awesome-omni-skills --skill telegram -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install diegosouzapw/awesome-omni-skills telegram --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/diegosouzapw/awesome-omni-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/telegram .claude/skills/telegram && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
telegram
GitHub stars
159
Token cost
~6.1k tokens
SKILL.md length
1,493 words
Files
24 (incl. scripts, references, assets)
Skills in repo
39
Repo updated
First seen
Licence
MIT

At a glance

Telegram Bot API - Integracao Profissional workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

  • Works in 7 steps: Abra o Telegram e busque @BotFather → Envie /newbot → Escolha nome de exibicao (ex: "Meu Bot… → …
  • The user needs Integracao completa com Telegram Bot API
  • SKILL.md covers Overview, When to Use This Skill, Operating Table and Workflow, plus 4 more sections
  • Runs TypeScript and Python scripts from its folder; calls python and curl; reaches api.telegram.org and github.com; needs SEU_TOKEN and TELEGRAM_BOT_TOKEN

What it does

Telegram is an agent skill from diegosouzapw/awesome-omni-skills. Telegram Bot API - Integracao Profissional workflow skill. Use this skill when the user needs Integracao completa com Telegram Bot API. Setup com BotFather, mensagens, webhooks, inline keyboards, grupos, canais. Boilerplates Node.js e Python and the operator should preserve the upstream workflow, copied support files, and provenance before merging or handing off.

Its SKILL.md is about 6.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 29 other files, including scripts, reference files and assets (for example `ORIGIN.md`, `assets/boilerplate/nodejs/package.json` and `assets/boilerplate/nodejs/src/bot-client.ts`).

It sits in Backend & APIs, covering Project scaffolding and Webhooks. It works with Telegram, Python and Node.js. The repository describes itself as: Public repository of AI coding skills, curated improved best-practice skills, and runtime surfaces for CLI, API, MCP, and A2A. The licence is MIT.

When your agent uses it

  • The user needs Integracao completa com Telegram Bot API
  • Tasks that involve Project scaffolding
  • Tasks that involve Webhooks

Example prompts

  • “/telegram”

Requirements

  • Python 3
  • Node.js
  • A credential in TELEGRAM_BOT_TOKEN

Workflow steps

7 steps, taken from the first numbered list in SKILL.md.

  1. Abra o Telegram e busque @BotFather
  2. Envie /newbot
  3. Escolha nome de exibicao (ex: "Meu Bot Incrivel")
  4. Escolha username (deve terminar com "bot", ex: meuincrivelbot)
  5. BotFather retorna o token - guarde com seguranca
  6. Comandos uteis do BotFather
  7. /setdescription - descricao do bot

What it can do on your machine

Read from SKILL.md and the folder at commit c3af004. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (TypeScript and Python, from the files we listed), which the agent can run.

    Shell commands in SKILL.md call:

    • python
    • curl

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • api.telegram.org
    • github.com
    • seu-dominio.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • SEU_TOKEN
    • TELEGRAM_BOT_TOKEN

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Telegram loads about 6.1k tokens when it runs, and up to ~14k if it reads all its reference files. Until then it costs about 94 tokens; SKILL.md has 1,493 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~94
When it runs · the whole SKILL.md, loaded when a task matches
~6.1k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~14k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from diegosouzapw/awesome-omni-skills at commit c3af004, republished under its MIT licence (© diegosouzapw). 1,493 words, ~6,113 tokens.

Download SKILL.mdSave it as .claude/skills/telegram/SKILL.md (or your agent's skills folder). This skill also uses 23 other files; get the full folder from GitHub.
name
telegram
description
Telegram Bot API - Integracao Profissional workflow skill. Use this skill when the user needs Integracao completa com Telegram Bot API. Setup com BotFather, mensagens, webhooks, inline keyboards, grupos, canais. Boilerplates Node.js e Python and the operator should preserve the upstream workflow, copied support files, and provenance before merging or handing off.
version
0.0.1
category
fullstack-web
tags
messaging, telegram, bots, webhooks, integracao, completa, com, bot
complexity
advanced
risk
caution
tools
claude-code, antigravity, cursor, gemini-cli, codex-cli, opencode
source
community
author
renat
date_added
2026-04-15
date_updated
2026-05-17

Telegram Bot API - Integracao Profissional

Overview

This public intake copy packages plugins/antigravity-awesome-skills-claude/skills/telegram from https://github.com/sickn33/antigravity-awesome-skills into the native Omni Skills editorial shape without hiding its origin.

Use it when the operator needs the upstream workflow, support files, and repository context to stay intact while the public validator and private enhancer continue their normal downstream flow.

This intake keeps the copied upstream files intact and uses the external_source block in metadata.json plus ORIGIN.md as the provenance anchor for review.

Telegram Bot API - Integracao Profissional

Imported source sections that did not map cleanly to the public headings are still preserved below or in the support files. Notable imported sections: How It Works, Decision Tree, Ou, Variaveis De Ambiente, Node.Js/Typescript, Python.

When to Use This Skill

Use this section as the trigger filter. It should make the activation boundary explicit before the operator loads files, runs commands, or opens a pull request.

  • When the user mentions "telegram" or related topics
  • When the user mentions "bot telegram" or related topics
  • When the user mentions "telegram bot" or related topics
  • When the user mentions "api telegram" or related topics
  • When the user mentions "chatbot telegram" or related topics
  • When the user mentions "mensagem telegram" or related topics

Operating Table

SituationStart hereWhy it matters
First-time usemetadata.jsonConfirms repository, branch, commit, and imported path through the external_source block before touching the copied workflow
Provenance reviewORIGIN.mdGives reviewers a plain-language audit trail for the imported source
Workflow executionreferences/advanced-features.mdStarts with the smallest copied file that materially changes execution
Supporting contextreferences/api-reference.mdAdds the next most relevant copied source file without loading the entire package
Handoff decision## Related SkillsHelps the operator switch to a stronger native skill when the task drifts

Workflow

This workflow is intentionally editorial and operational at the same time. It keeps the imported source useful to the operator while still satisfying the public intake standards that feed the downstream enhancer flow.

  1. Abra o Telegram e busque @BotFather
  2. Envie /newbot
  3. Escolha nome de exibicao (ex: "Meu Bot Incrivel")
  4. Escolha username (deve terminar com "bot", ex: meuincrivelbot)
  5. BotFather retorna o token - guarde com seguranca
  6. Comandos uteis do BotFather:
  7. /setdescription - descricao do bot
Imported Workflow Notes
Imported: Setup Com Botfather
  1. Abra o Telegram e busque @BotFather
  2. Envie /newbot
  3. Escolha nome de exibicao (ex: "Meu Bot Incrivel")
  4. Escolha username (deve terminar com "bot", ex: meu_incrivel_bot)
  5. BotFather retorna o token - guarde com seguranca
  6. Comandos uteis do BotFather:
    • /setdescription - descricao do bot
    • /setabouttext - texto "sobre" do bot
    • /setuserpic - foto de perfil
    • /setcommands - lista de comandos
    • /mybots - gerenciar bots existentes
    • /setinline - habilitar inline mode
    • /setprivacy - modo privacidade em grupos

Imported: Instalar: Pip Install Python-Telegram-Bot Python-Dotenv

import os from dotenv import load_dotenv from telegram import Update from telegram.ext import Application, CommandHandler, MessageHandler, filters, ContextTypes

load_dotenv()

async def start(update: Update, context: ContextTypes.DEFAULT_TYPE): await update.message.reply_text('Ola! Eu sou seu bot. Como posso ajudar?')

async def echo(update: Update, context: ContextTypes.DEFAULT_TYPE): await update.message.reply_text(f'Voce disse: {update.message.text}')

app = Application.builder().token(os.getenv('TELEGRAM_BOT_TOKEN')).build() app.add_handler(CommandHandler('start', start)) app.add_handler(MessageHandler(filters.TEXT & ~filters.COMMAND, echo)) app.run_polling()


#### Imported: Overview

Integracao completa com Telegram Bot API. Setup com BotFather, mensagens, webhooks, inline keyboards, grupos, canais. Boilerplates Node.js e Python.

#### Imported: How It Works

Skill para implementar bots profissionais no Telegram usando a Bot API oficial. Suporta Node.js/TypeScript e Python.

### Overview

A Telegram Bot API permite criar bots que interagem com usuarios via mensagens, comandos, inline keyboards, pagamentos e muito mais. Bots sao criados pelo @BotFather e autenticados via token unico.

**Base URL:** `https://api.telegram.org/bot<TOKEN>/METHOD_NAME`
**Metodos HTTP:** GET e POST
**Formatos de parametros:** query string, application/x-www-form-urlencoded, application/json, multipart/form-data (uploads)
**Limite de arquivos:** 50MB download, 20MB upload (via multipart), 50MB via URL

**Portas suportadas para webhooks:** 443, 80, 88, 8443

**Pre-requisitos:**
- Conta no Telegram
- Bot criado via @BotFather (fornece o token)
- Token no formato: `123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11`

Se o usuario nao tem um bot criado, oriente a conversar com @BotFather no Telegram e enviar `/newbot`.

---

## Examples

### Example 1: Ask for the upstream workflow directly

```text
Use @telegram to handle <task>. Start from the copied upstream workflow, load only the files that change the outcome, and keep provenance visible in the answer.

Explanation: This is the safest starting point when the operator needs the imported workflow, but not the entire repository.

Example 2: Ask for a provenance-grounded review
text
Review @telegram against metadata.json and ORIGIN.md, then explain which copied upstream files you would load first and why.

Explanation: Use this before review or troubleshooting when you need a precise, auditable explanation of origin and file selection.

Example 3: Narrow the copied support files before execution
text
Use @telegram for <task>. Load only the copied references, examples, or scripts that change the outcome, and name the files explicitly before proceeding.

Explanation: This keeps the skill aligned with progressive disclosure instead of loading the whole copied package by default.

Example 4: Build a reviewer packet
text
Review @telegram using the copied upstream files plus provenance, then summarize any gaps before merge.

Explanation: This is useful when the PR is waiting for human review and you want a repeatable audit packet.

Best Practices

Treat the generated public skill as a reviewable packaging layer around the upstream repository. The goal is to keep provenance explicit and load only the copied source material that materially improves execution.

  • Provide clear, specific context about your project and requirements
  • Review all suggestions before applying them to production code
  • Combine with other complementary skills for comprehensive analysis
  • Keep the imported skill grounded in the upstream repository; do not invent steps that the source material cannot support.
  • Prefer the smallest useful set of support files so the workflow stays auditable and fast to review.
  • Keep provenance, source commit, and imported file paths visible in notes and PR descriptions.
  • Point directly at the copied upstream files that justify the workflow instead of relying on generic review boilerplate.
Imported Operating Notes
Imported: Best Practices
  • Provide clear, specific context about your project and requirements
  • Review all suggestions before applying them to production code
  • Combine with other complementary skills for comprehensive analysis

Troubleshooting

Problem: The operator skipped the imported context and answered too generically

Symptoms: The result ignores the upstream workflow in plugins/antigravity-awesome-skills-claude/skills/telegram, fails to mention provenance, or does not use any copied source files at all. Solution: Re-open metadata.json, ORIGIN.md, and the most relevant copied upstream files. Check the external_source block first, then restate the provenance before continuing.

Problem: The imported workflow feels incomplete during review

Symptoms: Reviewers can see the generated SKILL.md, but they cannot quickly tell which references, examples, or scripts matter for the current task. Solution: Point at the exact copied references, examples, scripts, or assets that justify the path you took. If the gap is still real, record it in the PR instead of hiding it.

Show full SKILL.md (614 more words)Show less
Problem: The task drifted into a different specialization

Symptoms: The imported skill starts in the right place, but the work turns into debugging, architecture, design, security, or release orchestration that a native skill handles better. Solution: Use the related skills section to hand off deliberately. Keep the imported provenance visible so the next skill inherits the right context instead of starting blind.

  • @20-andruia-niche-intelligence-v2 - Use when the work is better handled by that native specialization after this imported skill establishes context.
  • @advogado-criminal-v2 - Use when the work is better handled by that native specialization after this imported skill establishes context.
  • @advogado-especialista-v2 - Use when the work is better handled by that native specialization after this imported skill establishes context.
  • @agent-memory-systems-v2 - Use when the work is better handled by that native specialization after this imported skill establishes context.

Additional Resources

Use this support matrix and the linked files below as the operator packet for this imported skill. They should reflect real copied source material, not generic scaffolding.

Resource familyWhat it gives the reviewerExample path
referencescopied reference notes, guides, or background material from upstreamreferences/advanced-features.md
examplesworked examples or reusable prompts copied from upstreamexamples/n/a
scriptsupstream helper scripts that change execution or validationscripts/send_message.py
agentsrouting or delegation notes that are genuinely part of the imported packageagents/n/a
assetssupporting assets or schemas copied from the source packageassets/boilerplate/nodejs/.env.example
Imported Reference Notes
Imported: Decision Tree
O usuario precisa criar um bot?
├── SIM → Secao "Setup com BotFather" abaixo
└── NAO → Qual linguagem?
    ├── Node.js/TypeScript
    └── Python
    → O que quer fazer?
       ├── Enviar mensagens → Secao "Tipos de Mensagem"
       ├── Receber mensagens → Secao "Receber Updates"
       ├── Teclados interativos → Secao "Keyboards"
       ├── Gerenciar grupos/canais → references/chat-management.md
       ├── Webhook setup → references/webhook-setup.md
       ├── Inline mode → references/advanced-features.md
       ├── Pagamentos → references/advanced-features.md
       ├── Bot de atendimento com IA → Secao "Automacao com IA"
       └── Referencia completa da API → references/api-reference.md

Para iniciar um projeto do zero com boilerplate pronto:

bash
python scripts/setup_project.py --language nodejs --path ./meu-bot-telegram

#### Imported: Ou

python scripts/setup_project.py --language python --path ./meu-bot-telegram

Para testar se o token do bot funciona:

bash
python scripts/test_bot.py --token "SEU_TOKEN"

Para enviar uma mensagem de teste:

bash
python scripts/send_message.py --token "SEU_TOKEN" --chat-id "CHAT_ID" --text "Hello!"

Imported: Variaveis De Ambiente
env
TELEGRAM_BOT_TOKEN=123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11
Imported: Node.Js/Typescript
typescript
// Instalar: npm install node-telegram-bot-api dotenv
// Para TypeScript: npm install -D @types/node-telegram-bot-api typescript
import TelegramBot from 'node-telegram-bot-api';
import dotenv from 'dotenv';
dotenv.config();

const bot = new TelegramBot(process.env.TELEGRAM_BOT_TOKEN!, { polling: true });

bot.onText(/\/start/, (msg) => {
  bot.sendMessage(msg.chat.id, 'Ola! Eu sou seu bot. Como posso ajudar?');
});

bot.on('message', (msg) => {
  if (msg.text && !msg.text.startsWith('/')) {
    bot.sendMessage(msg.chat.id, `Voce disse: ${msg.text}`);
  }
});
Imported: Python
python

#### Imported: Sem Biblioteca (Http Puro)

```python
import requests

TOKEN = "SEU_TOKEN"
BASE = f"https://api.telegram.org/bot{TOKEN}"

#### Imported: Verificar Bot

r = requests.get(f"{BASE}/getMe")
print(r.json())

#### Imported: Enviar Mensagem

r = requests.post(f"{BASE}/sendMessage", json={
    "chat_id": "CHAT_ID",
    "text": "Hello from pure HTTP!",
    "parse_mode": "HTML"
})
print(r.json())

Imported: Tipos De Mensagem

O Telegram suporta diversos tipos de conteudo. Todos os metodos aceitam chat_id, reply_parameters (para responder), reply_markup (para keyboards), disable_notification e protect_content.

Imported: Html (Recomendado)

await bot.send_message( chat_id=chat_id, text="<b>Negrito</b>, <i>italico</i>, <code>codigo</code>, <a href='https://example.com'>link</a>", parse_mode="HTML" )

Imported: Markdownv2 (Escapar Caracteres Especiais: _ * [ ] ( ) ~ ` > # + - = | { } . !)

await bot.send_message( chat_id=chat_id, text="Negrito, italico, codigo, link", parse_mode="MarkdownV2" )


#### Imported: Foto (Por Url, File_Id Ou Upload)

await bot.send_photo(chat_id, photo="https://example.com/img.jpg", caption="Legenda aqui")

#### Imported: Documento

await bot.send_document(chat_id, document=open("relatorio.pdf", "rb"), caption="Relatorio mensal")

#### Imported: Video

await bot.send_video(chat_id, video="https://example.com/video.mp4", caption="Assista!")

#### Imported: Audio

await bot.send_audio(chat_id, audio=open("musica.mp3", "rb"), title="Minha Musica")

#### Imported: Voz (Ogg Com Opus)

await bot.send_voice(chat_id, voice=open("audio.ogg", "rb"))

#### Imported: Localizacao

await bot.send_location(chat_id, latitude=-23.5505, longitude=-46.6333)

#### Imported: Contato

await bot.send_contact(chat_id, phone_number="+5511999999999", first_name="Joao")

#### Imported: Enquete

await bot.send_poll(
    chat_id, question="Qual sua cor favorita?",
    options=["Azul", "Verde", "Vermelho"],
    is_anonymous=False
)

#### Imported: Grupo De Midias

await bot.send_media_group(chat_id, media=[
    InputMediaPhoto("url1", caption="Foto 1"),
    InputMediaPhoto("url2"),
    InputMediaVideo("url3")
])

#### Imported: Acao De Chat (Typing, Upload_Photo, Etc.)

await bot.send_chat_action(chat_id, action="typing")
Imported: Node.Js Equivalente
typescript
// Foto
bot.sendPhoto(chatId, 'https://example.com/img.jpg', { caption: 'Legenda' });

// Documento
bot.sendDocument(chatId, fs.createReadStream('relatorio.pdf'), { caption: 'Relatorio' });

// Localizacao
bot.sendLocation(chatId, -23.5505, -46.6333);

// Enquete
bot.sendPoll(chatId, 'Qual sua cor favorita?', ['Azul', 'Verde', 'Vermelho']);

Imported: Inline Keyboard (Botoes Dentro Da Mensagem)
python
from telegram import InlineKeyboardButton, InlineKeyboardMarkup

keyboard = InlineKeyboardMarkup([
    [InlineKeyboardButton("Opcao A", callback_data="opt_a"),
     InlineKeyboardButton("Opcao B", callback_data="opt_b")],
    [InlineKeyboardButton("Abrir Site", url="https://example.com")],
    [InlineKeyboardButton("Compartilhar", switch_inline_query="texto")]
])

await bot.send_message(chat_id, "Escolha uma opcao:", reply_markup=keyboard)

#### Imported: Handler De Callback

async def button_callback(update: Update, context: ContextTypes.DEFAULT_TYPE):
    query = update.callback_query
    await query.answer()  # Importante: sempre responder o callback
    await query.edit_message_text(f"Voce escolheu: {query.data}")

app.add_handler(CallbackQueryHandler(button_callback))
Imported: Reply Keyboard (Teclado Customizado)
python
from telegram import ReplyKeyboardMarkup, KeyboardButton

keyboard = ReplyKeyboardMarkup(
    [[KeyboardButton("Enviar Localizacao", request_location=True)],
     [KeyboardButton("Enviar Contato", request_contact=True)],
     ["Opcao 1", "Opcao 2"]],
    resize_keyboard=True,
    one_time_keyboard=True
)

await bot.send_message(chat_id, "Escolha:", reply_markup=keyboard)
Imported: Remover Teclado
python
from telegram import ReplyKeyboardRemove
await bot.send_message(chat_id, "Teclado removido", reply_markup=ReplyKeyboardRemove())

Imported: Receber Updates

Existem duas formas de receber updates: Long Polling e Webhooks.

Imported: Long Polling (Desenvolvimento)

Mais simples, ideal para desenvolvimento. O bot faz requisicoes periodicas ao servidor do Telegram.

python

#### Imported: Python-Telegram-Bot Ja Faz Isso Automaticamente

app.run_polling(allowed_updates=Update.ALL_TYPES)
typescript
// node-telegram-bot-api com polling
const bot = new TelegramBot(token, { polling: true });
Imported: Webhooks (Producao)

Para producao, webhooks sao mais eficientes. O Telegram envia updates via POST para sua URL HTTPS.

Leia references/webhook-setup.md para configuracao completa com Express, Flask, ngrok e deploy.

Setup rapido:

python

#### Imported: Flask Webhook

from flask import Flask, request
import requests

app = Flask(__name__)
TOKEN = "SEU_TOKEN"
BASE = f"https://api.telegram.org/bot{TOKEN}"

@app.route(f"/webhook/{TOKEN}", methods=["POST"])
def webhook():
    update = request.get_json()
    if "message" in update and "text" in update["message"]:
        chat_id = update["message"]["chat"]["id"]
        text = update["message"]["text"]
        requests.post(f"{BASE}/sendMessage", json={
            "chat_id": chat_id,
            "text": f"Recebi: {text}"
        })
    return "OK", 200

#### Imported: Registrar Webhook

requests.post(f"{BASE}/setWebhook", json={
    "url": "https://seu-dominio.com/webhook/" + TOKEN,
    "allowed_updates": ["message", "callback_query"],
    "secret_token": "seu_secret_seguro_aqui"
})

Imported: Comandos Do Bot

Registre comandos para aparecerem no menu do Telegram:

python
from telegram import BotCommand

await bot.set_my_commands([
    BotCommand("start", "Iniciar o bot"),
    BotCommand("help", "Ver comandos disponiveis"),
    BotCommand("settings", "Configuracoes"),
    BotCommand("status", "Ver status do servico"),
])

Via HTTP:

bash
curl -X POST "https://api.telegram.org/bot$TOKEN/setMyCommands" \
  -H "Content-Type: application/json" \
  -d '{"commands":[{"command":"start","description":"Iniciar o bot"},{"command":"help","description":"Ajuda"}]}'

Imported: Automacao Com Ia

Padrao para bot de atendimento com IA (Claude, GPT, etc.):

python
from telegram import Update
from telegram.ext import Application, MessageHandler, filters, ContextTypes
import anthropic  # ou openai

client = anthropic.Anthropic()
user_conversations = {}  # chat_id -> messages history

async def ai_response(update: Update, context: ContextTypes.DEFAULT_TYPE):
    chat_id = update.message.chat_id
    user_text = update.message.text

    # Indicar que esta digitando
    await context.bot.send_chat_action(chat_id, "typing")

    # Manter historico
    if chat_id not in user_conversations:
        user_conversations[chat_id] = []

    user_conversations[chat_id].append({"role": "user", "content": user_text})

    # Chamar IA
    response = client.messages.create(
        model="claude-sonnet-4-20250514",
        max_tokens=1024,
        system="Voce e um assistente prestativo. Responda em portugues.",
        messages=user_conversations[chat_id]
    )

    reply = response.content[0].text
    user_conversations[chat_id].append({"role": "assistant", "content": reply})

    # Limitar historico (ultimas 20 mensagens)
    if len(user_conversations[chat_id]) > 20:
        user_conversations[chat_id] = user_conversations[chat_id][-20:]

    await update.message.reply_text(reply)

app = Application.builder().token(TOKEN).build()
app.add_handler(MessageHandler(filters.TEXT & ~filters.COMMAND, ai_response))
app.run_polling()

Imported: Editar Texto

await bot.edit_message_text( chat_id=chat_id, message_id=msg.message_id, text="Texto atualizado!", parse_mode="HTML" )

Imported: Editar Markup (Botoes)

await bot.edit_message_reply_markup( chat_id=chat_id, message_id=msg.message_id, reply_markup=new_keyboard )

Imported: Deletar Mensagem

await bot.delete_message(chat_id=chat_id, message_id=msg.message_id)

Imported: Encaminhar Mensagem

await bot.forward_message( chat_id=dest_chat_id, from_chat_id=source_chat_id, message_id=msg.message_id )


---

#### Imported: Tratamento De Erros

```python
from telegram.error import TelegramError, BadRequest, TimedOut, NetworkError

async def safe_send(bot, chat_id, text, **kwargs):
    """Envio com retry e tratamento de erros."""
    max_retries = 3
    for attempt in range(max_retries):
        try:
            return await bot.send_message(chat_id, text, **kwargs)
        except TimedOut:
            if attempt < max_retries - 1:
                await asyncio.sleep(2 ** attempt)
                continue
            raise
        except BadRequest as e:
            if "chat not found" in str(e).lower():
                print(f"Chat {chat_id} nao encontrado")
                return None
            raise
        except NetworkError:
            if attempt < max_retries - 1:
                await asyncio.sleep(2 ** attempt)
                continue
            raise

Imported: Rate Limits
  • Mensagens em chat privado: ~30 msg/segundo
  • Mensagens em grupo: ~20 msg/minuto por grupo
  • Broadcast geral: ~30 msg/segundo no total
  • Bulk notifications: use asyncio.sleep(0.05) entre envios para evitar flood

Se receber erro 429 (Too Many Requests), respeite o retry_after retornado.


Imported: Referencia De Arquivos
TopicoArquivo
Setup de webhooksreferences/webhook-setup.md
Gerenciamento de chatsreferences/chat-management.md
Recursos avancadosreferences/advanced-features.md
Referencia completa da APIreferences/api-reference.md
Boilerplate Node.jsassets/boilerplate/nodejs/
Boilerplate Pythonassets/boilerplate/python/
Exemplos de payloadsassets/examples/
Imported: Common Pitfalls
  • Using this skill for tasks outside its domain expertise
  • Applying recommendations without understanding your specific context
  • Not providing enough project context for accurate analysis
Imported: Limitations
  • Use this skill only when the task clearly matches the scope described above.
  • Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
  • Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.

© diegosouzapw, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 23 other files (scripts, references, assets) in skills/telegram of diegosouzapw/awesome-omni-skills.

  • SKILL.md
  • ORIGIN.md
  • assets/boilerplate/nodejs/.env.example
  • assets/boilerplate/nodejs/package.json
  • assets/boilerplate/nodejs/src/bot-client.ts
  • assets/boilerplate/nodejs/src/handlers.ts
  • assets/boilerplate/nodejs/src/index.ts
  • assets/boilerplate/nodejs/tsconfig.json
  • assets/boilerplate/python/.env.example
  • assets/boilerplate/python/bot.py
  • assets/boilerplate/python/requirements.txt
  • assets/boilerplate/python/webhook_server.py
  • assets/examples/inline-keyboard.json
  • assets/examples/webhook-payloads.json
  • metadata.json
  • … and 9 more

Open the folder on GitHubat commit c3af004

Compare with similar skills

Telegram next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Telegram compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Telegram this skilldiegosouzapw/awesome-omni-skills159—~6.1kAutomated safety check: PassMIT
Telegrammajiayu000/claude-skill-registry6663 repos~4kAutomated safety check: PassMIT
Adobe App Builder Action Scaffolderadobe/skills196—~3.1kAutomated safety check: PassApache-2.0
Telegram Bot Builderaiskillstore/marketplace4303 repos~2.2kAutomated safety check: NotesNone
Whatsapp Cloud APImajiayu000/claude-skill-registry6663 repos~4.5kAutomated safety check: PassMIT
Tlgrtlgrcli/tlgr1931 repos~1.5kAutomated safety check: PassMIT

Similar skills

  • Telegram

    majiayu000/claude-skill-registry

    Integracao completa com Telegram Bot API. An agent skill from majiayu000/claude-skill-registry.

    666 GitHub starsUsed in 3 repos~4k tokens
    Backend & APIsAuto-check passed
  • Scaffolds, implements, deploys and debugs Adobe Runtime actions in App Builder projects, with templates for webhooks, events, database CRUD, sequences and Asset Compute workers.

    196 GitHub stars~3.1k tokensUpdated today
    Backend & APIsAuto-check passed
  • Telegram Bot Builder

    aiskillstore/marketplace

    Expert in building Telegram bots that solve real problems - from simple automation to complex AI-powered bots.

    430 GitHub starsUsed in 3 repos~2.2k tokens
    Productivity & AutomationAuto-check: notes
  • Whatsapp Cloud API

    majiayu000/claude-skill-registry

    Integracao com WhatsApp Business Cloud API (Meta). An agent skill from majiayu000/claude-skill-registry.

    666 GitHub starsUsed in 3 repos~4.5k tokens
    Backend & APIsAuto-check passed
  • Tlgr

    tlgrcli/tlgr

    Read and act on a personal Telegram account from the terminal with the tlgr CLI (MTProto user account, not a bot).

    193 GitHub starsUsed in 1 repo~1.5k tokens
    Backend & APIsAuto-check passed
  • Telegram Development Guide

    2025Emma/vibe-coding-cn

    Chinese-language guide to building on Telegram: bots through the Bot API, Mini Apps in JavaScript and custom clients through TDLib, with Python examples.

    23k GitHub starsUsed in 1 repo~3.7k tokens
    Backend & APIsAuto-check passed

More from diegosouzapw/awesome-omni-skills

All 39 skills in this repo
  • Content Creator

    diegosouzapw/awesome-omni-skills

    Content Creator workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

    159 GitHub stars~4k tokensUpdated 3 mo ago
    Auto-check passed
  • Helm Chart Scaffolding

    diegosouzapw/awesome-omni-skills

    Helm Chart Scaffolding workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

    159 GitHub stars~2.4k tokensUpdated 3 mo ago
    Auto-check passed
  • Prompt Engineering

    diegosouzapw/awesome-omni-skills

    Prompt Engineering Patterns workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

    159 GitHub stars~3.4k tokensUpdated 3 mo ago
    Auto-check passed
  • Prompt Engineering Patterns

    diegosouzapw/awesome-omni-skills

    Prompt Engineering Patterns workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

    159 GitHub stars~4k tokensUpdated 3 mo ago
    Auto-check passed
  • Prompt Library

    diegosouzapw/awesome-omni-skills

    📝 Prompt Library workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

    159 GitHub stars~3.1k tokensUpdated 3 mo ago
    Auto-check passed
  • Protocol Reverse Engineering

    diegosouzapw/awesome-omni-skills

    Protocol Reverse Engineering workflow skill. An agent skill from diegosouzapw/awesome-omni-skills.

    159 GitHub stars~3.8k tokensUpdated 3 mo ago
    Auto-check passed

Questions about Telegram

What does Telegram do?

Telegram Bot API - Integracao Profissional workflow skill. An agent skill from diegosouzapw/awesome-omni-skills. Telegram is an agent skill from diegosouzapw/awesome-omni-skills. Telegram Bot API - Integracao Profissional workflow skill.

When should I use Telegram?

Telegram fits situations like: the user needs Integracao completa com Telegram Bot API; tasks that involve Project scaffolding; tasks that involve Webhooks.

How do I install Telegram in Claude Code?

Run `npx skills add diegosouzapw/awesome-omni-skills --skill telegram -a claude-code`. Or copy the skill folder (skills/telegram in diegosouzapw/awesome-omni-skills) into .claude/skills/telegram in your project. Claude Code loads it when a task matches its description.

How do I install Telegram in Codex?

Run `npx skills add diegosouzapw/awesome-omni-skills --skill telegram -a codex`. Or copy the skill folder (skills/telegram in diegosouzapw/awesome-omni-skills) into .agents/skills/telegram in your project. Codex loads it when a task matches its description.

Can I use Telegram in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add diegosouzapw/awesome-omni-skills --skill telegram -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/telegram, .gemini/skills/telegram, .github/skills/telegram and .opencode/skills/telegram in your project.

What does Telegram need to run?

Going by SKILL.md and its folder, Telegram needs TypeScript and Python for the scripts in its folder, the command-line tools its instructions call (python and curl) and credentials named SEU_TOKEN and TELEGRAM_BOT_TOKEN. Our summary lists: Python 3; Node.js; A credential in TELEGRAM_BOT_TOKEN.

Does Telegram access the network?

SKILL.md names 3 domains. In commands or code: api.telegram.org, github.com and seu-dominio.com; the agent is likely to contact these when it follows the instructions. This is read from the text; nothing was executed.

Is Telegram safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Telegram use?

Telegram is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Telegram use?

About 6.1k tokens (SKILL.md is roughly 24k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 8.3k tokens, read only when the agent opens those files.

What are the alternatives to Telegram?

Skills that share tags, products or a category with Telegram: Telegram (majiayu000/claude-skill-registry, 666 stars), Adobe App Builder Action Scaffolder (adobe/skills, 196 stars), Telegram Bot Builder (aiskillstore/marketplace, 430 stars) and Whatsapp Cloud API (majiayu000/claude-skill-registry, 666 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Telegram?

diegosouzapw (a GitHub user) maintains it in diegosouzapw/awesome-omni-skills, which has 159 GitHub stars. The repository holds 39 skills in this directory. The repository was last updated on July 8, 2026.

Source: diegosouzapw/awesome-omni-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.