There is a simple query to google API
https://maps.googleapis.com/maps/api/geocode/json?address=&components=country:Russia&language=ru&key=MY_API_KEY
Use the OpenCage Geocoder API service, it has continent has one of its values.
https://geocoder.opencagedata.com/api
Possible values of _type include (but are not limited to): building, road, village, neighbourhood, city, county, postcode, state_district, state, region, island, country, continent, ficticious, unknown