Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

API for finding Administrative Divisions

Is there any endpoint or API to query Wikipedia, DBpedia or something similar to get all the Wikipedia pages of all the countries and its respective administrative divisions?

I've tried to find in DBpedia the way to know the administrative sub-divisions of a given region but I couldn't do it.

like image 765
arodriguezdonaire Avatar asked Oct 20 '22 05:10

arodriguezdonaire


1 Answers

I would instead query against Wikidata and then convert the reults to Wikipedia pages.

You can use Sweden as an example for how a country and its subdivisions are structured.

For the querying you can use either https://query.wikidata.org (SPARQL) or http://wdq.wmflabs.org

like image 156
Lokal_Profil Avatar answered Nov 11 '22 14:11

Lokal_Profil