Any way to run this bot for specific users ?
Closed this issue · 11 comments
Anyway to run this bot for specific users ?
Because i want to run this bot for private purpose.so anyway to prevent others using it by comamands or env vars ?
Add chat filter for inline query in inline.py file (line no.8)
Example:
@Client.on_inline_query(filters.chat(1234))
Replace 1234
by your chat id
can i add more chat ids like 123,456,555 ?
Yes, use list in filter. For example filters.chat([1234, 5678, 54311])
like files are not showing while i search as inline
Try with filters.user
instead of filters.chat
Try with
filters.user
instead offilters.chat
Tried.But one problem,still everyone can access the bot and files.
i changed as like you said @Client.on_inline_query(filters.user(MY NUMERIC ID))
and still the bot is working for other peoples
By filters.user
other users can't access files in inline search, please check it again
put ids in list format - filters.user([1234, 5678, 54311])
Use put ids in list format -
filters.user([1234, 5678, 54311])
Worked.Thank you for your great help