Parsing all user comments under posts (discussion) in certain channel(s) and export in file
Note: Count only comments whose defined like reply to post
pip install -r requirements.txt
1. Go to https://my.telegram.org/apps. Create application and get credential data API_ID and API_HASH
API_ID
- Telegram app credential from step 1
API_HASH
- Telegram app credential from step 1
TARGET_USER_ID
- Telegram user/channel ID whose comments need to be found
POSTS_LIMIT
- Count of posts which will process. The number define the last N posts
Only channel username (ex. https:/t.me/durov, username is durov)
channel_username_1
channel_username_2
channel_username_3
python bot.py
After start you should authorize in telegram account and script will create file account.session for further work
After script end working all found data will be export in file export.csv
Data format
datetime, channel name, channel username, comment, link
Pull requests are welcome.