[Python] How can I get message views in Telegram bot without API hash?

Discussão em 'Python' iniciado por Stack, Junho 25, 2025.

  1. Stack

    Stack Membro Participativo

    I built a Telegram bot using Telebot in Python, and one of its main functions is to count the number of views on certain posts in specific channels or groups.

    However, even when I used the requests module to call Telegram’s API and used the getMessagesViews method — with correct parameters like peer (which I set as the bot's username) — I keep getting a “not found” error.

    It seems this method only works with Telethon, but I don’t have an API ID or API hash, and as an Iranian user, I can’t even obtain them.

    What should I do?! Please suggest a solution — but please make sure it’s secure.

    Continue reading...

Compartilhe esta Página