Guide: Incoming Webhooks for Telegram

Demo

Getting started

  1. Create incoming webhook. You can create incoming webhooks here. Save the Access Secret securely because it will be the authorization key to send a message to telegram via Incoming Webhook.
  2. Invite @BobOpsBot into any chat group or initiate a direct message with it. This will give @BobOpsBot the correct access to send messages to the Telegram Chat.
  3. After you have initiated contact with @BobOpsBot, you can use the /connect Telegram Command with your account's Email Address and the Incoming Webhook's Access Key to establish connection between the Incoming Webhook and the Telegram Chat.
  4. 🎉 Now you can call the Incoming Webhook API to start sending messages to the connected Telegram Chat!

API Doc

POST https://bobops.net/api/incoming_webhooks

Request Headers
KeyValueDescription
AuthorizationBearer {access-secret}Authorization for making API Request
Content-Typeapplication/jsonIndicate the media type of the resource. Only application/json is supported.
Request Body (JSON)
KeySample ValueDescription
text"*Status all green! 🟢*\n \n_Salute_ 🫡"Telegram's MarkdownV2 style
Response
Status CodeResponseDescription
200{ "text": "sent!" } Incoming webhook sent successfully. There is currently no variation of the response.
400No BodyRequest body not JSON or "text" key is not provided.
401No BodyNo or invalid Authorization header provided.
404No Body
  • Incoming webhook cannot be found.
  • Incoming webhook has not been connected to a Telegram Chat yet.
  • BobOpsBot does not have the permission to send messages to the connected Telegram Chat.