Google geo parameter

You can use the geo parameter with Google targets in a few different ways:

  • Target using full location name as provided in Google csv found here, for example: London,England,United Kingdom
curl -u SPusername:SPpassword -X POST --url https://scraper-api.smartproxy.com/v2/scrape -H "Content-Type: application/json" -d "{\"target\": \"google_search\", \"query\": \"history\", \"parse\": \"true\", \"geo\": \"London,England,United Kingdom\"}"
  • Target using only the full country name, for example: United Kingdom
curl -u SPusername:SPpassword -X POST --url https://scraper-api.smartproxy.com/v2/scrape -H "Content-Type: application/json" -d "{\"target\": \"google_search\", \"query\": \"history\", \"parse\": \"true\", \"geo\": \"United Kingdom\"}"
  • Using coordinates and radius, for example: lat: 32.4827, lng: -22.9384, rad: 5000
curl -u SPusername:SPpassword -X POST --url https://scraper-api.smartproxy.com/v2/scrape -H "Content-Type: application/json" -d "{\"target\": \"google_search\", \"query\": \"history\", \"parse\": \"true\", \"geo\": \"lat: 32.4827, lng: -22.9384, rad: 5000\"}"

There are exceptions and above formats will not work in all situations, in which case you will get an error stating that.