gem.bot/howto

Run a bot for a business account

What it is

A business bot connects to a person's account and works in their private chats. It receives incoming messages and, as far as the owner allows, replies, marks them read, deletes them, edits the profile, moves Stars or posts stories. Since May 2026 every Telegram user can connect one.

How to do it

  1. In @BotFather, enable Secretary Mode.
  2. The user connects your bot in Settings › Chat Automation and picks its chats, such as everyone but contacts, or only new chats.
  3. You get a business_connection update: id, user, user_chat_id, rights, is_enabled. Act on the latest rights.
  4. Handle business_message, edited_business_message and deleted_business_messages, each with a business_connection_id.
  5. Reply with sendMessage or other send methods plus that business_connection_id.
  6. With the matching right: readBusinessMessage, deleteBusinessMessages, setBusinessAccountBio, transferBusinessAccountStars, postStory and more.
  7. The owner's Manage Bot button in a managed chat opens your bot with /start bizChat<user_chat_id>.

Watch out

With Gem

Gem doesn't connect to business accounts. Nearby: Gem holds @gembot for your project; it answers in your groups, handles join requests, posts to channels and takes Stars for offers.

Sources

Open in Telegram