API de Mensajes

Envía y gestiona mensajes a través de tus bots

La API de Mensajes te permite enviar varios tipos de mensajes a chats de Telegram, incluyendo texto, fotos, documentos y más. También puedes difundir mensajes a múltiples chats simultáneamente.

Tipos de mensajes soportados

Texto

Texto plano con soporte de markdown

Foto

Imágenes con leyenda opcional

Documento

Archivos de hasta 50MB

Video

Archivos de video con streaming

Voz

Mensajes de audio

Endpoints

POST
/api/messages/send

Enviar un mensaje de texto a un chat

botIdchatIdtextparseMode
POST
/api/messages/send-photo

Enviar una foto a un chat

botIdchatIdphotocaption
POST
/api/messages/send-document

Enviar un documento/archivo a un chat

botIdchatIddocumentcaption
POST
/api/messages/broadcast

Enviar un mensaje a múltiples chats

botIdchatIdstextdelay
GET
/api/messages/:chatId

Obtener historial de mensajes de un chat

chatIdlimitbefore

Ejemplo: Enviar un mensaje

curl -X POST https://api.botlaunch.io/api/messages/send \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "botId": "bot_abc123",
    "chatId": "-100123456789",
    "text": "Hello from BotLaunch!",
    "parseMode": "Markdown"
  }'

Siguiente: API de Usuarios

Aprende a gestionar usuarios y sus permisos.

Users API