If you don’t need a “subtext” / region, and you send the full names of cities (without using autocomplete in some context):
An alternative is to search for places (including cities) rather than adcities . This will give the graph identifier for the location, which can then be simply connected to the graph. Facebook.com
Request example:
https://graph.facebook.com/search?q=sundsvall%20sweden&type=place&access_token=[TOKEN]
This will give:
{ "data": [ { "name": "Sundsvall, Sweden", "category": "City", "location": { "latitude": 62.3833, "longitude": 17.3 }, "id": "110103992352737" }, { "name": "Ladyland of Sweden", "category": "Local business", "location": { "street": "Thulegatan 12", "city": "Sundsvall", "country": "Sweden", "zip": "85232", "latitude": 62.389481631972, "longitude": 17.303409784226 }, "id": "170645612982568" }, ...
And just as well as Ladyland, you can drop it and everything else in the answer that does not match the “category”: “city”. Unfortunately, I’m not sure about the possibility to limit the results in cities ahead of time, but it seems that cities are consistently sorted high for this type of query, so the "query then filter" method should work.
Chart ID for Sundsvall, top result:
https://graph.facebook.com/110103992352737
source share