Hello, I already have such python script which is able to scrape members from PUBLIC and PRIVATE groups.
Also you will be able to filter members by their recent activity. For example, you will be able to scrape members which were active: last 1 hour, last 24 hours, last week, last 2 week, last month and all members.
Also I want to clarify some details.
What is the difference between a Group and a Channel on Telegram?
Group - Where everyone can write.
Channel - Where normal users can only read messages.
P.S. You can try to use my Telegram scraper bot which can scrape members from public groups - @TGScraperBot.