Analytics

Every profile analytics endpoint with a cURL, Python and Node sample: daily Google and Facebook metrics and weekly Bing views for a location.

Profile analytics say how often a location was seen and acted on at each publisher: impressions, page views, direction requests, calls and website clicks. There are three endpoints, one per publisher, and all three are reads, so a Read key is enough. Every metric is a time series of { startTime, value } points; the API returns no scalar totals, so the sums you show are ones you compute.

Endpoints at a glance

MethodPathWhat it doesReference
GET/locations/{locationId}/google-analyticsNine daily Google Business Profile series.Google analytics
GET/locations/{locationId}/facebook-analyticsFive daily Facebook Page series.Facebook analytics
GET/locations/{locationId}/bing-analyticsOne weekly Bing Places series.Bing analytics

All three share the same parameters. fromDate and toDate are YYYY-MM-DD, both optional; omit them and the publisher's default recent window is used. The path takes the base64 Relay id or the plain number. A value that is neither returns 200 with the insights object set to null and an errors array, which looks like a disconnected profile, so check errors first.

Read Google metrics for a date range

GET /locations/{locationId}/google-analytics returns data.googleInsights with one daily series per metric. total is profile impressions, search plus maps; it does not include the action metrics. Use it for a before-and-after visibility report around a data change.

NameInRequiredNotes
locationIdpathYesBase64 Relay id or numeric databaseId.
fromDatequeryNoStart of the range, YYYY-MM-DD. Defaults to a recent window.
toDatequeryNoEnd of the range, YYYY-MM-DD.
Google
curl "https://listingsapi.com/api/v4/locations/TG9jYXRpb246MTgwMDI4OQ==/google-analytics?fromDate=2026-08-01&toDate=2026-08-31" \-H "Authorization: API $LISTINGSAPI_KEY"
JSON
{  "data": {    "googleInsights": {      "total": [        { "startTime": "2026-08-01T00:00:00+00:00", "value": 412 },        { "startTime": "2026-08-02T00:00:00+00:00", "value": 388 }      ],      "search": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 300 }],      "maps": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 112 }],      "directionsAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 24 }],      "phoneAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 8 }],      "websiteAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 41 }],      "businessBookings": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 0 }],      "businessFoodOrders": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 0 }],      "businessFoodMenuClicks": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 0 }]    }  }}

Each point's startTime is the day the count is bucketed under. In the sample, total on the first day is 412, which is 300 search plus 112 maps.

SeriesMeaning
totalProfile impressions, search plus maps.
searchImpressions in Google Search results, desktop and mobile combined.
mapsImpressions in Google Maps results, desktop and mobile combined.
directionsActionDirection requests to the location.
phoneActionClicks on the call button.
websiteActionClicks through to the website.
businessBookingsBookings started from the profile.
businessFoodOrdersFood orders placed from the profile.
businessFoodMenuClicksClicks on the food-menu link.

A metric is null, not an empty array, when the location has no Google data for the window or its Google profile is not connected. Handle null and [] the same way when you aggregate.

Read Facebook metrics for a date range

GET /locations/{locationId}/facebook-analytics has the same shape under data.facebookInsights with five daily series. It requires the location's Facebook Page to be connected. ctaAction is how you measure a "Book now" or "Call now" button over a campaign window.

NameInRequiredNotes
locationIdpathYesBase64 Relay id or numeric databaseId.
fromDatequeryNoStart of the range, YYYY-MM-DD. Defaults to a recent window.
toDatequeryNoEnd of the range, YYYY-MM-DD.
Facebook
curl "https://listingsapi.com/api/v4/locations/TG9jYXRpb246MTgwMDI4OQ==/facebook-analytics?fromDate=2026-08-01&toDate=2026-08-31" \-H "Authorization: API $LISTINGSAPI_KEY"
JSON
{  "data": {    "facebookInsights": {      "views": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 120 }],      "ctaAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 5 }],      "directionsAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 3 }],      "phoneAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 2 }],      "websiteAction": [{ "startTime": "2026-08-01T00:00:00+00:00", "value": 9 }]    }  }}
SeriesMeaning
viewsTotal Page views.
ctaActionClicks on the Page's call-to-action button.
directionsActionDirection requests via the Page.
phoneActionCalls initiated from the Page.
websiteActionClicks through to the website from the Page.

There is no page-likes metric. Every series comes back null when the Page has no data for the range or is not connected, so check for null before iterating.

Read Bing views for a date range

GET /locations/{locationId}/bing-analytics returns a single series, data.bingInsights.views, bucketed by week rather than day. Each point is one week's view count starting at startTime. Data refreshes every Monday for the preceding week, so the newest complete week is the latest you will see. Fetch a multi-month range for a trend line; it is not suited to day-level attribution.

NameInRequiredNotes
locationIdpathYesBase64 Relay id or numeric databaseId.
fromDatequeryNoStart of the range, YYYY-MM-DD. Defaults to a recent window.
toDatequeryNoEnd of the range, YYYY-MM-DD.
Bing
curl "https://listingsapi.com/api/v4/locations/TG9jYXRpb246MTgwMDI4OQ==/bing-analytics?fromDate=2026-06-01&toDate=2026-08-31" \-H "Authorization: API $LISTINGSAPI_KEY"
JSON
{  "data": {    "bingInsights": {      "views": [        { "startTime": "2026-06-01T00:00:00+00:00", "value": 73 },        { "startTime": "2026-06-08T00:00:00+00:00", "value": 58 }      ]    }  }}
SeriesMeaning
viewsBing Places profile views, one point per week.

Unlike Google and Facebook, Bing reports no data as an empty views array with a 200, not as null. Treat both as "nothing to show", and test for length == 0 if you want a "no data" label, since an empty array sums to 0.

Errors you will see

The reference pages name no resource-specific error codes for analytics. The cases you will meet:

CodeMeaningFix
401 with SY90001Missing or invalid API key.Send Authorization: API $LISTINGSAPI_KEY.
200 with googleInsights, facebookInsights or bingInsights set to null and an errors arrayThe locationId is neither a number nor a decodable Relay id.Pass the base64 id a read endpoint returned. Do not URL-encode it.
200 with a null metric (Google, Facebook) or an empty views array (Bing), and no errorsNo data for the window, or the publisher is not connected.Show "unavailable", not zero. Connect the account.
429Rate limit.Wait for Retry-After. See Rate limits.

The full list is in Error codes.

Next steps