Would the same process work for other tlds?
In this case it seems to work with “participating tlds”, whichever those are.
But you're right for ccTLDs -- everyone uses their own format and most don't even allow you to get the zone file. There are some companies though that provide similar lists from crawling data (e.g. https://zonefiles.io/).