Google Maps Posts API
The Google Maps Posts API retrieves posts and updates from Google Business listings. Pass a data_id obtained from the Google Maps Search API to get posts with descriptions, dates, images, and links.
Endpoint:
https://api.scrapingdog.com/google_maps/postsAPI Parameters
π
Authentication
api_keyRequiredYour personal API key. Available on your dashboard
Type: String
π
Location
data_idRequiredIt is the Google Maps data ID. You can get this by entering the location name as the query in our Google Maps API.
Type: String
π
Pagination
next_page_tokenOptionalThe next_page_token is used to get the next page results.
Type: String
API Examples
Code to Integrate
curl "https://api.scrapingdog.com/google_maps/posts?api_key=APIKEY&data_id=0x89c259a61c75684f:0x79d31adb123348d2"
import requests params = { "api_key": "APIKEY", "data_id": "0x89c259a61c75684f:0x79d31adb123348d2", } response = requests.get("https://api.scrapingdog.com/google_maps/posts", params=params) print(response.json())
const axios = require("axios"); axios.get("https://api.scrapingdog.com/google_maps/posts", { params: { api_key: "APIKEY", data_id: "0x89c259a61c75684f:0x79d31adb123348d2" } }).then(res => console.log(res.data));
<?php $params = http_build_query(["api_key" => "APIKEY", "data_id" => "0x89c259a61c75684f:0x79d31adb123348d2"]); $response = file_get_contents("https://api.scrapingdog.com/google_maps/posts?" . $params); print_r(json_decode($response, true));
require "net/http" require "json" uri = URI("https://api.scrapingdog.com/google_maps/posts") uri.query = URI.encode_www_form(api_key: "APIKEY", data_id: "0x89c259a61c75684f:0x79d31adb123348d2") puts JSON.parse(Net::HTTP.get_response(uri).body)
HttpURLConnection con = (HttpURLConnection) new URL("https://api.scrapingdog.com/google_maps/posts?api_key=APIKEY&data_id=0x89c259a61c75684f:0x79d31adb123348d2").openConnection(); con.setRequestMethod("GET");
API Response
{
"location_details": {
"title": "Blue Bottle Coffee",
"logo": "https://lh3.googleusercontent.com/places/logo..."
},
"post_data": [
{
"description": "Our summer blend is here! Stop by and try our limited-edition cold brew made with single-origin beans from Ethiopia.",
"date": "Aug 4, 2022",
"image": "https://lh3.googleusercontent.com/places/post-image...",
"link": "https://posts.google.com/..."
},
{
"description": "We're now open on Sundays from 8 AM to 5 PM. Come enjoy your weekend with a perfect cup.",
"date": "Jul 18, 2022",
"image": "https://lh3.googleusercontent.com/places/post-image-2...",
"link": "https://posts.google.com/..."
}
],
"next_page_token": "EvgDKYQi49-NlUMIDw..."
}