Links

Google My Business (GMB)

Options for posting via the API to Google My Business (Google Business Profile)

GMB API Endpoint

Overview

There are four types of Google My Business, a.k.a Google Business Profile, posts. In the below example, the post text is posted as an update to the user's Google business page. Find out more about Google My Business (GMB).
You must claim your Google My Business page before linking it with Ayrshare. Be sure to choose the Google account that is an admin of your GMB page during link authorization.
You can access your GMB manage console at https://business.google.com/
Product posts cannot be created via the Google My Business API at this time.
JSON for a basic post with an just text to GMB, which will appear in the "What's New" section of :
{
"post": "The best GMB ever #best https://www.google.com",
"platforms": ["gmb"]
}
or JSON for a basic post with an an image to GMB:
{
"post": "The best GMB ever #best https://www.google.com",
"mediaUrls": ["https://img.ayrshare.com/012/gb.jpg"],
"platforms": ["gmb"]
}
If your video doesn't end in a known video extension such as mp4, please use the isVideo parameter. See the /post endpoint for details.

Google My Business Posting Requirements

Please be sure your post does not contain the following. Google will reject your post and the post will show as "This post is no longer available" or with a "Rejected" label in the Google Console:
  • Phone numbers. Google will reject all posts containing phone numbers.
  • Spam, false claims, or false representation.
  • Off-topic post that doesn’t pertain to your business.
  • Duplicate content.
  • Inappropriate content.
  • Offensive language.
Please see Google My Business' Content Policy for more information.

Standard Post (What's New)

A standard post appears in the "Posts" GMB section and categorized as "What's New". It can contains post text, an image, or a Call to Action (see below).
Videos are not supported for Standard post.
These posts will appear in the "Posts -> What's New" section in the GMB management console.
{
"post": "A wonderful post",
"platforms": ["gmb"],
"mediaUrls": ["https://img.ayrshare.com/012/gb.jpg"], // optional
"gmbOptions": {
"callToAction": { // optional
"actionType": "learn_more",
"url": "https://www.ayrshare.com"
}
}
}

Image or Video Post

Just and image or video can be added to your GMB location, which will appear in the "Photos" section of the GMB console. Only one image or video is allowed per post. Note, the post text is not used, but required by the endpoint. For example, a restaurant can make a post to promote a new menu item. These may not have Call to Action.
These posts will appear in the "Photos" section in the GMB management console.
{
"post": "What an image!",
"platforms": ["gmb"],
"mediaUrls": ["https://img.ayrshare.com/012/gb.jpg"], // required
"gmbOptions": {
"isPhotoVideo": true, //required
"category": "product" // optional
}
}

Product Category

You can specify a product category for an image or video so the media is categorized in the "Photos" section of the GMB console. For example, if an image has the category "product", it will appear under the "Product" tab in Photos.
Some categories are not allowed for certain business types. For example, Ayrshare could not use food_and_drink since we are not in the food/drink industry.
Available Categories:
  • cover: Cover photo. A location has only one cover photo.
  • profile: Profile photo. A location has only one profile photo.
  • logo: Logo photo.
  • exterior: Exterior media.
  • interior: Interior media.
  • product: Product media.
  • at_work: At work media.
  • food_and_drink: Food and drink media.
  • menu: Menu media.
  • common_area: Common area media.
  • rooms: Rooms media.
  • teams: Teams media.

Events Post

Promote an event at your business. Events require a title, start and end dates, and can include a video. For example, a real estate agent may advertise an open house showing signing. Event support Call to Action.
Optionally include an image with the mediaUrls parameter.
Videos are not supported for Events.
These posts will appear in the "Posts -> Events" section in the GMB management console.
{
"post": "A great event!",
"platforms": ["gmb"],
"mediaUrls": ["https://img.ayrshare.com/012/gb.jpg"], // optional
"gmbOptions": {
"event": {
"title": "Check this event out.", // required
"startDate": "2021-08-12T20:17:46.384Z", // required
"endDate": "2021-09-12T20:17:46.384Z" // required
}
}
}

Offers Post

Provide promotional sales or offers from your business. Offers require a title as well as start and end dates and times. A "View offer" action button is automatically added to the post. You can also include a photo, description, coupon code, link, and terms and conditions with the post. For example, a toy store may advertise 20% off all beanie babies for a week.
Include an image with the mediaUrls parameter.
Videos are not supported for Offers.
These posts will appear in the "Posts -> Offers" section in the GMB management console.
{
"post": "A great offer for everyone!",
"platforms": ["gmb"],
"gmbOptions": {
"offer": {
"title": "Great Sale.", // required
"startDate": "2021-08-12T20:17:46.384Z", // required
"endDate": "2021-09-12T20:17:46.384Z", // required
"couponCode": "BOGO-JET-CODE", // required
"redeemOnlineUrl": "https://www.ayrshare.com", // required
"termsConditions": "Offer only valid if you can prove you are a time traveler" // required
}
}
}

Call to Action

Provide general information about your business and appears as an action button. For example, a website might promote a Learn More button to redirect to their website.
A Call to Action can be added to a Standard post or Event. Offers can not have Call to Actions.
Include an image with the mediaUrls parameter.
{
"post": "Take this action!",
"platforms": ["gmb"],
"mediaUrls": ["https://img.ayrshare.com/012/gb.jpg"], //optional
"gmbOptions": {
"callToAction": {
"actionType": "order", // required
"url": "https://www.ayrshare.com" // required for all action types but "call"
}
}
}
The actionType is displayed as a button on the post. Possible values are:
  • book: Prompts a user to book an appointment, table, or something similar.
  • order: Prompts a user to order something.
  • shop: Prompts a user to browse a product catalog.
  • learn_more: Prompts a user to see additional details on a website.
  • sign_up: Prompts a user to register, sign up, or join something.
  • call: Prompts a user to call a business. The url field is not required for call. However, you must first have set a phone number in your Google Business Profile for the call action to appear on the post.
The url parameter is the URL the user will be directed to upon clicking.