0

I am using Google Places API Web Service, specifically nearbysearch to search for places around me. However, some of the places names that I get are in languages other than English, some are Chinese and Arabic, I tried to include language=en in the url. However, with no luck. It is worth mentioning that same places names are in English if I look them up in www.google.com/maps

The url I am using:

https://maps.googleapis.com/maps/api/place/nearbysearch/json?location=25.1677738,55.4030409&radius=500&type=food&language=en&name=&key=YourKey

Please note that I have removed my key from the url.

This is part of the result I am getting with Arabic place name

{
     "geometry" : {
        "location" : {
           "lat" : 25.167926,
           "lng" : 55.4015231
        }
     },
     "icon" : "https://maps.gstatic.com/mapfiles/place_api/icons/shopping-71.png",
     "id" : "328ca6a7bb4dd48eb44215ed32fa5676fca8e462",
     "name" : "سوبر ماركت بوماز ٢٤ساعة",
     "place_id" : "ChIJlcEHXrVmXz4RJH7IVn7Rps4",
     "reference" : "CoQBfwAAAI8pnOqGRA6E71Mmztnk8ueSA7kS9bn5idY3S5V0_D_JZP2F9knryHUervQXA_RZL3-9KZJH55NrX0dz4p1R1GUQbGz4jXGoDQMJemisTLpiu41dm8-wgZT6XzXsDUeLLo6QbENam3hM2gCXPzpjTu4F7GsV4t4bIX5FhDQ-SufVEhDYboMkA1reMj20kM4AAvzGGhStwclS0fE9rWQkn5LTUcxiio-3vA",
     "scope" : "GOOGLE",
     "types" : [
        "grocery_or_supermarket",
        "food",
        "store",
        "point_of_interest",
        "establishment"
     ],
     "vicinity" : "U2 - Italy U17 - Dubai"
  }
Steve Mclean
  • 149
  • 1
  • 12

1 Answers1

0

Looked around the community for a while and found this a post that is regarding the inconsistency in the language used in Google Places API results. And as per the answer, it seems that it is actually a correct behavior, from the answer:

Even if you specify a language, it will return the response in that language only if there is one available, if not it will return the response in the language it was originally entered in.

There are workarounds included in there that I think that would be helpful.

Nimantha
  • 6,405
  • 6
  • 28
  • 69
AL.
  • 36,815
  • 10
  • 142
  • 281