Saltar al contenido principal

🤖 Bot de Telegram

PulseHub se conecta a Telegram a través de la Bot API. Cuando los usuarios envían mensajes a tu bot de Telegram, los mensajes aparecen en PulseHub.


Requisitos Previos​

Una cuenta de Telegram y acceso a @BotFather para crear un bot.


Pasos de Configuración​

1. Crear un Bot con BotFather​

  1. Abre Telegram y busca @BotFather
  2. Envía /newbot
  3. Elige un nombre para mostrar (ej. "Soporte Acme")
  4. Elige un nombre de usuario terminado en bot (ej. acmesupport_bot)
  5. BotFather responde con tu Bot Token

2. Agregar el Canal en PulseHub​

  1. Ve a Canales → Agregar Canal
  2. Selecciona Telegram
  3. Pega tu Bot Token
  4. Haz clic en Guardar Canal
  5. Copia la URL del Webhook

3. Registrar el Webhook con Telegram​

Abre esta URL en tu navegador:

https://api.telegram.org/bot{TU_BOT_TOKEN}/setWebhook?url={TU_URL_WEBHOOK_PULSEHUB}

Telegram responde con: {"ok": true, "result": true, "description": "Webhook was set"}

4. Probar​

Abre tu bot en Telegram y envía un mensaje. Debería aparecer en PulseHub en segundos.


Requisitos de Webhook de Telegram​

  • La URL del webhook debe usar HTTPS con un certificado SSL válido
  • Telegram espera una respuesta 200 dentro de 60 segundos

Problemas Comunes​

SíntomaCausa Probable
Webhook no configuradoLa URL debe ser HTTPS con un certificado válido
El bot no respondeVerifica que telegram_chat_id esté en contacts.external_ids
Mensajes antiguos re-entregadosNormal al re-registrar el webhook