How to Set Up a Telegram Guardian Bot for Join Requests
How to Set Up a Telegram Guardian Bot for Join Requests
TL;DR. Telegram's Bot API 10.1, released June 11, 2026, added "Guardian Bots" β a dedicated role for screening who gets into your channel or group. A guard bot receives
ChatJoinRequestupdates carrying aquery_id, decides who to approve, and replies through the newanswerChatJoinRequestQuerymethod β optionally showing a mini-app screen first viasendChatJoinRequestWebApp. This guide covers what changed, how the pieces fit together, and how to wire up a screening flow without hand-rolling everything from scratch.
Want the screening logic to run alongside your posting schedule instead of as a separate project? See how Autogram's automation layer handles channel events.
Prerequisites
- A Telegram channel or group with Approve new members (join requests) turned on.
- A bot created via @BotFather, added as an administrator with the right to manage join requests.
- Basic familiarity with the Bot API (webhook or
getUpdates) β this guide assumes you already receive updates. - Optional: a Web App (an HTTPS page) if you want to screen applicants through
sendChatJoinRequestWebAppinstead of a plain approve/decline.
Step 1 β What Bot API 10.1 added for Telegram Guardian Bots
Before Bot API 10.1, a bot handling join requests worked with the ChatJoinRequest object and a single method, answerChatJoinRequest(chat_id, user_id, approved) β a blunt accept-or-reject. Telegram's June 11, 2026 changelog layered a "query" concept on top of that:
ChatJoinRequest.query_idβ a new optional field that identifies an individual join request as a query the bot can respond to.answerChatJoinRequestQuery(chat_id, user_id, query_id, approved, invite_link?)β the new method built around that identifier. It still approves or declines, but ties the response to a specific query instead of just a rawuser_id.User.supports_join_request_queriesβ a flag on the bot's owngetMeresponse, saying "yes, I can be assigned to handle these."ChatFullInfo.guard_botβ a field, visible only to chat administrators, naming which bot currently screens join requests for that chat.
Telegram's own announcement frames the feature in plain terms: "Add AI bots as admins to process join requests" β and adds that they "can also smite the unrighteous who post in the chat, if you want them to." That second half matters: a guard bot's job doesn't stop at the front door. The same bot can stay attached to moderate content after admission, if you grant it the rights to do so.
Step 2 β Assign your Telegram Guardian Bot
There is no dedicated "assign guardian" API call in Bot API 10.1 β assignment works the way bot admin rights always have: add the bot to the chat and grant it the right to manage join requests. Once that is done, and once the bot's getMe response reports supports_join_request_queries: true, Telegram treats it as the chat's guard bot, reflected back to admins as ChatFullInfo.guard_bot.
Two things worth checking before you rely on this in production:
- Confirm the flag. Call
getMeand checksupports_join_request_queries. If your bot library predates Bot API 10.1, update it β older versions will not expose the field at all. - Confirm the admin right. The bot needs the specific "manage join requests" permission. Being an admin is not automatically enough if that one right was left unchecked when you added the bot.
Step 3 β Handle the query and respond
When someone requests to join, your bot receives a chat_join_request update carrying the ChatJoinRequest object, now with query_id populated. From there you have two paths.
Direct decision. If you already have enough signal β an allowlist, a prior interaction, a bio keyword match β call answerChatJoinRequestQuery immediately, passing chat_id, user_id, the query_id from the update, and approved. Pass invite_link too if the chat is private and you want to hand the approved user a working link back.
Screen first, then decide. If you want the applicant to answer a question or agree to rules before admission, call sendChatJoinRequestWebApp(chat_id, app_url, button_text?) to hand them a Web App β your own HTTPS page β before responding. The applicant completes whatever flow you built (a short quiz, a rules acknowledgment, an email-domain check), and your backend calls answerChatJoinRequestQuery once it has an answer.
This two-step pattern β screen, then decide β is the shape most early write-ups settled on after the June 2026 launch: it separates detection from enforcement, so a false decline does not need a full appeal process, just a fresh join request.
Common mistakes
- Assuming
chat_idplususer_idis enough. Bot API 10.1'sanswerChatJoinRequestQueryrequiresquery_idtoo. Code written against the olderanswerChatJoinRequestmethod will not compile against the new signature β check your library's changelog before assuming compatibility. - Treating
guard_botas a per-request answer.guard_bottells you which bot currently handles a chat's queries β it does not tell you the outcome of any specific request. Log your own approve/decline decisions if you need an audit trail; Telegram does not keep one for you beyond the chat's own admin log. - Skipping the mini-app path and hand-building a chat conversation instead.
sendChatJoinRequestWebAppexists so screening does not have to happen as a clunky back-and-forth in a private message. A Web App gives you a real form, and it is the pattern Telegram's own announcement highlights first. - Granting moderation rights without a policy. A guard bot that can also remove messages is powerful. Decide up front what triggers a removal, or you will end up debugging false positives after members have already noticed.
Related reading
- Telegram Bot API 10.0 Guest Mode: What Channel Operators Need to Know β the release right before this one, covering guest-mode replies and bot-to-bot messaging.
- Telegram Super Channels: The Multi-Author Setup Guide for Brand Teams β for teams managing who posts, not just who joins.
- Telegram Managed Bots: What We Know Before the April Launch β platform-hosted bots, a related shift in how much infrastructure you need to automate a channel.
FAQ
What is a Telegram Guardian Bot?
A Guardian Bot is a bot a chat's admins assign to process join requests, and optionally to moderate messages afterward. It is not a new bot type β it is a role your existing bot can take on once it supports Bot API 10.1's join request queries.
Do I need Bot API 10.1 to build this?
Yes. query_id on ChatJoinRequest, the answerChatJoinRequestQuery method, sendChatJoinRequestWebApp, and the guard_bot and supports_join_request_queries fields were all added in Bot API 10.1, released June 11, 2026. Older library versions will not expose them.
How is this different from the old answerChatJoinRequest method?
The pre-10.1 method took only chat_id, user_id, and approved β a blunt approve-or-decline. The new query-based flow ties the response to a specific query_id, and pairs with sendChatJoinRequestWebApp so you can screen before you decide, not just decide.
Can a Guardian Bot reject someone and let them try again?
Yes. Declining a join request does not ban the user. They can send a new join request, and your bot will receive a new query with a new query_id.
Does the guard bot have to be the same bot that posts my content?
No. Nothing in Bot API 10.1 requires it. Many operators run a dedicated screening bot with narrower permissions than their main posting or automation bot, which limits the blast radius if the screening logic has a bug.
Can I see which bot is currently guarding my chat?
Yes, if you are a chat administrator: ChatFullInfo.guard_bot names it. The field is admin-only β regular members and the public cannot see it.
What happens if I do not build a screening flow β do join requests still work?
Yes. Nothing about Bot API 10.1 removes the old approve/decline behavior. Guardian Bots are additive; a chat without a designated guard bot behaves exactly as before.
Can the same bot both screen new members and moderate existing ones?
Yes, if you grant it the relevant admin rights alongside managing join requests. Telegram's own announcement calls this out directly as part of the same feature, not a separate one.
Bottom line
Bot API 10.1 turns "who gets in" from a binary approve-or-decline into an actual pipeline β screen, then decide β without forcing you to build a bot-side conversation flow from nothing. If your channel already gets more join requests than you can vet by hand, this is the moment to wire one up. Start automating the rest of your channel operations with Autogram once the front door is handled.
Related Posts

How to Add a Telegram Mini App to Your Channel (No-Code Guide)
Learn how to attach a Telegram Mini App to your channel and start accepting Stars payments β without writing a single line of code. A practical operator guide for 2026.

TON to Fiat for Channel Operators: Fragment Withdrawal Walkthrough
Step-by-step guide to withdrawing Telegram channel revenue β ad TON and Stars β via Fragment, converting on a crypto exchange, and banking the proceeds.

Refunding Telegram Stars: How refundStarPayment Actually Works
When to refund a Telegram Stars charge, how to call refundStarPayment, the no-partial-refund rule, /paysupport handling, and clean audit-log reconciliation.
Subscribe to our newsletter
Get the latest Telegram growth tips, automation strategies, and platform updates delivered to your inbox.
Or follow our Telegram channel