Places Suggestions API

Parameter:

  • radius is in km.
  • lat is latitude
  • lng is longitude
  • query is keyword

Optional Parameter:

  • details=1 (default is 0) returns more details.

This is the result with details=0, it only returns the unique place name.

<autoCompletePlaces>
   <autoCompletePlace>
        <description>Walmart</description>
    </autoCompletePlace>
    <autoCompletePlace>
         <description>Walmart Supercentre</description>
    </autoCompletePlace>
</autoCompletePlaces>

This is the result with details=1

<autoCompletePlaces>
   <autoCompletePlaceautoCompletePlace>
   <description>Walmart Supercentre, Toronto, ON, Canada</description>
   <id>b57c10f5820ef83ba849f1b74e88a5d087a6b141</id>
   <types>establishment</types>
</autoCompletePlace>
<autoCompletePlace>
    <description>Walmart, Lawrence Avenue West, Toronto, ON, Canada</description>
    <id>447fd9c90cf39fc3a2122cd161f888ec10a6524c</id>
    <types>establishment</types>
</autoCompletePlace>
<autoCompletePlace>
    <description>Walmart, Toronto, ON, Canada</description>
    <id>da787310ca6603a7a52a2be1635993298c2ad6a1</id>
    <types>establishment</types>
</autoCompletePlace>
...