0% found this document useful (0 votes)
162 views3 pages

Google Maps Add API (JSON Format) :: Sample Body

The document describes the Google Maps Place API which allows adding and deleting places by sending HTTP requests to a specific URL. It provides JSON and XML formats to add a place by sending a POST request with details like location, name, types. The response returns a place ID. To delete a place, a POST request is sent with the place ID and the response returns a status. Sample requests and responses are given for both adding and deleting places.

Uploaded by

Karan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
162 views3 pages

Google Maps Add API (JSON Format) :: Sample Body

The document describes the Google Maps Place API which allows adding and deleting places by sending HTTP requests to a specific URL. It provides JSON and XML formats to add a place by sending a POST request with details like location, name, types. The response returns a place ID. To delete a place, a POST request is sent with the place ID and the response returns a status. Sample requests and responses are given for both adding and deleting places.

Uploaded by

Karan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Google Maps Add API (JSON Format):

Complete URL :http://216.10.245.166/maps/api/place/add/json?key= qaclick123

Base URL : http://216.10.245.166


Resource : /maps/api/place/add/json
Parameters: key

Http request : POST

Note : Key value is hardcoded and it is always qaclick123

Sample Body :
{
"location":{
"lat" : -38.383494,
"lng" : 33.427362
},
"accuracy":50,
"name":"Frontline house",
"phone_number":"(+91) 983 893 3937",
"address" : "29, side layout, cohen 09",
"types": ["shoe park","shop"],
"website" : "http://google.com",
"language" : "French-IN"
}

Sample Response

{
"status": "OK",
"place_id": "928b51f64aed18713b0d164d9be8d67f",
"scope": "APP",
"reference": "736f3c9bec384af62a184a1936d42bb0736f3c9bec384af62a184a1936d42bb0",
"id": "736f3c9bec384af62a184a1936d42bb0"
}

Google Maps Add API (XML Format):


Complete URL :http://216.10.245.166/maps/api/place/add/xml?key= qaclick123

Base URL : http://216.10.245.166


Resource : /maps/api/place/add/xml
Parameters: key
Http request : POST

Note : Key value is hardcoded and it is always qaclick123

Sample Body :
<?xml version="1.0" encoding="UTF-8" ?>
<root>
<location>
<lat>-38.383494</lat>
<lng>33.427362</lng>
</location>
<accuracy>50</accuracy>
<name>The Mens store</name>
<phone_number>(+91) 983 893 3937</phone_number>
<address>Anna Salai, Chennai</address>
<types>shoe park</types>
<types>kadai</types>
<website>http://google.com</website>
<language>tamil-IN</language>
</root>

Sample Response

<?xml version="1.0"?>
<response>
<status>OK</status>
<place_id>fdd2f7bf74afae3f1462833d43a53678</place_id>
<scope>APP</scope>
<reference>326f3c1e773a000ee7b0f1ed529f900e326f3c1e773a000ee7b0f1ed529f900e</reference>
<id>326f3c1e773a000ee7b0f1ed529f900e</id>
</response>

Google Maps Delete API (JSON):

Complete URL : http://216.10.245.166/maps/api/place/delete/json?key=qaclick123

Base URL : http://216.10.245.166


Resource : /maps/api/place/delete/json
Parameters: key

Http request : POST

Sample Body :
{
"place_id":"928b51f64aed18713b0d164d9be8d67f" //(This value comes from Add place response)
}
Sample Response

{
"status": "OK"
}

Google Maps Delete API (XML):

Complete URL : http://216.10.245.166/maps/api/place/delete/xml?key=qaclick123

Base URL : http://216.10.245.166

Resource : /maps/api/place/delete/xml
Parameters: key

Http request : POST

Sample Body :
<?xml version="1.0" encoding="UTF-8" ?>
<root>
<place_id>fdd2f7bf74afae3f1462833d43a53678</place_id>
</root>

Sample Response

<?xml version="1.0"?>
<response>
<status>OK</status>
</response>

You might also like