that’s interesting.
it looks to me like Taiwan (place id 7887) is no longer defined as a country within iNaturalist. it does retain the admin level 0, which countries use, but it no longer has place type 12, which defines countries (or at least used to define countries). it looks like the place was last updated on 7 March 2022, and as far as i know, only staff can update these kinds of places. so i assume the change came from staff, though staff (@loarie? @tiwane?) will have to speak to whether or not this change is intentional.
from my perspective, without relying on place type 12, there’s no other documented way to efficiently get a list of countries from iNaturalist, unless i manually define the list of countries myself (which i’m not going to do.)
here’s what i see from the old API response for Taiwan (https://www.inaturalist.org/places.json?ancestor_id=97395&latitude=23.7785353908&longitude=120.8662501376):
{"id":7887,"name":"Taiwan","display_name":"Taiwan","code":"TW","latitude":"23.7785353908","longitude":"120.8662501376","swlat":"20.6477","swlng":"116.6605","nelat":"26.4354","nelng":"122.1585","woeid":23424971,"parent_id":97395,"check_list_id":8288,"place_type":null,"source_name":"225","source_identifier":"0.0","created_at":"2009-12-28T11:54:03.000-06:00","updated_at":"2022-03-07T08:39:12.662-06:00","user_id":null,"ancestry":"97395","slug":"taiwan","source_id":10464,"admin_level":0,"uuid":"9bc198b0-bf6f-4f75-a59f-3d7bd3c23ca6","place_type_name":null}
just for comparison, here’s what the API returns for China (https://www.inaturalist.org/places.json?ancestor_id=97395&latitude=36.507419842&longitude=103.9687408191&place_type=12): {"id":6903,"name":"China","display_name":"China","code":"CN","latitude":"36.507419842","longitude":"103.9687408191","swlat":"18.1096","swlng":"73.5577","nelat":"53.5609","nelng":"134.7739","woeid":23424781,"parent_id":97395,"check_list_id":7239,"place_type":12,"source_name":"49","source_identifier":"0.0","created_at":"2009-09-24T01:18:18.000-05:00","updated_at":"2017-12-03T12:53:13.794-06:00","user_id":null,"ancestry":"97395","slug":"china","source_id":10464,"admin_level":0,"uuid":"0135b593-8893-43ed-a4b2-6c081069cdee","place_type_name":"Country"}