My Business
2.5K members online now
2.5K members online now
For developers who are using the Google My Business API to manage locations
Guide Me
star_border
Reply

Updating Attributes Not Wiping Google Updated Values for Attributes

[ Edited ]
Follower ✭ ✭ ☆
# 1
Follower ✭ ✭ ☆

Hi there,

 

I do a Google Updated call on one of my locations and I see there is a GoogleUpdated mask on attributes that Google believes are applicable for my location.

 

Some of these are incorrect and so I am sending a patch request to update Attributes for a location with the correct values. When I do a get request for that location, I see my new attributes are present which is expected.

 

When I do a GoogleUpdated call on the same location again, I still see Google updated values for attributes.

 

My understanding from this thread was that, once I push my own values for attributes (or any other field that has a GoogleUpdated mask), the GoogleUpdated mask should now be dropped (until Google crawls the web again and finds more up to date info than the info I've provided.

 

Clarification on this would be great.

 

 

 

2 Expert replyverified_user

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

Google Employee
# 2
Google Employee

Hi @Patrick L,

 

Can you please provide us with a specific locationId for the location in which you can’t override the Google updated version of the specified location by making further edits to the location attributes with a PATCH call via the Google My Business API? Please provide this information so that we can help you troubleshoot the issue further.

 

Thanks,

Terry

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

[ Edited ]
Follower ✭ ✭ ☆
# 3
Follower ✭ ✭ ☆

Thanks @Terry W,

https://mybusiness.googleapis.com/v3/accounts/113311880217305589942/locations/15066564058077106958:g...

In testing, I have patched the attributes to just be "attributeId": "serves_beer", "attributeId": "serves_beer_craft" and "attributeId": "serves_happy_hour", setting them all to true.

A Get request to that location shows those three attributes live. However the GoogleUpdated call still has the attributes that were previously suggested, despite us patching.

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

Google Employee
# 4
Google Employee

Hi @Patrick L,

 

Just for clarification, when you perform a GET request, are you seeing the three values you mentioned set as true (as you patched them to be), or still as the value in the GoogleUpdated call?

 

Thanks, 

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

Follower ✭ ✭ ☆
# 5
Follower ✭ ✭ ☆

Hi @Andrew H,


Thanks. So the patch request is successfully updating the attributes to the 3 I'm specifying.

 

And then the normal get request shows the 3 attributes.

 

But the GoogleUpdated get request still has the 8 or so Google Updated values, which I understood were supposed to be dropped if we patched that particular field (in this instance, the attributes field).

 

I have tested again, patching 4 attributes to the location.

After successfully patching Attributes, the results of this Get https://mybusiness.googleapis.com/v3/accounts/113311880217305589942/locations/15066564058077106958 is 

 

{
  "storeCode": "108", 
  "additionalCategories": [
    {
      "name": "American Restaurant", 
      "categoryId": "gcid:american_restaurant"
    }, 
    {
      "name": "Bar", 
      "categoryId": "gcid:bar"
    }, 
    {
      "name": "Cafe", 
      "categoryId": "gcid:cafe"
    }, 
    {
      "name": "Restaurant", 
      "categoryId": "gcid:restaurant"
    }
  ], 
  "openInfo": {
    "status": "OPEN"
  }, 
  "name": "accounts/113311880217305589942/locations/15066564058077106958", 
  "locationKey": {
    "plusPageId": "100659650070891935246", 
    "placeId": "ChIJwR_6w0yI-4gRyC4TibgL0I4"
  }, 
  "metadata": {}, 
  "regularHours": {
    "periods": [
      {
        "openDay": "SUNDAY", 
        "closeDay": "SUNDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "SUNDAY", 
        "closeDay": "SUNDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }, 
      {
        "openDay": "MONDAY", 
        "closeDay": "MONDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "MONDAY", 
        "closeDay": "MONDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }, 
      {
        "openDay": "TUESDAY", 
        "closeDay": "TUESDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "TUESDAY", 
        "closeDay": "TUESDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }, 
      {
        "openDay": "WEDNESDAY", 
        "closeDay": "WEDNESDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "WEDNESDAY", 
        "closeDay": "WEDNESDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }, 
      {
        "openDay": "THURSDAY", 
        "closeDay": "THURSDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "THURSDAY", 
        "closeDay": "THURSDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }, 
      {
        "openDay": "FRIDAY", 
        "closeDay": "FRIDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "FRIDAY", 
        "closeDay": "FRIDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }, 
      {
        "openDay": "SATURDAY", 
        "closeDay": "SATURDAY", 
        "openTime": "00:00", 
        "closeTime": "02:00"
      }, 
      {
        "openDay": "SATURDAY", 
        "closeDay": "SATURDAY", 
        "openTime": "11:00", 
        "closeTime": "24:00"
      }
    ]
  }, 
  "locationName": "Wild Wing Cafe - Bluffton", 
  "photos": {
    "logoPhotoUrl": "https://lh3.googleusercontent.com/s5W7EyW_i0z_6Q6Qin4da1G9nb19-h8i7A4Gf8rkeY0zCOYSsKcAEOhhZH_VcVKt_3s=s0", 
    "profilePhotoUrl": "https://lh3.googleusercontent.com/Qis3hScwtGmLhmHV8vVCamzSL_J6eBNI2ACeuzDQnYZyIFIb6vt4RqQ6gPsjXXB1xGVyxduE=s0", 
    "coverPhotoUrl": "https://lh3.googleusercontent.com/X-0yFEr9_3QY1Xzw3iS0j7csZCOznw5UbcCdWtCwSybw2RlxdsQsbnIYDkGIlUy2row=fcrop64=1,00000c81ffff9ee4"
  }, 
  "primaryPhone": "(843) 837-9453", 
  "address": {
    "postalCode": "29910", 
    "country": "US", 
    "administrativeArea": "South Carolina", 
    "addressLines": [
      "1188 Fording Island Rd"
    ], 
    "locality": "Bluffton"
  }, 
  "websiteUrl": "http://www.wildwingcafe.com/locations/bluffton-sc", 
  "attributes": [
    {
      "values": [
        true
      ], 
      "valueType": "BOOL", 
      "attributeId": "serves_alcohol"
    }, 
    {
      "values": [
        true
      ], 
      "valueType": "BOOL", 
      "attributeId": "serves_beer"
    }, 
    {
      "values": [
        true
      ], 
      "valueType": "BOOL", 
      "attributeId": "serves_beer_craft"
    }, 
    {
      "values": [
        true
      ], 
      "valueType": "BOOL", 
      "attributeId": "serves_happy_hour"
    }
  ], 
  "primaryCategory": {
    "name": "Chicken Wings Restaurant", 
    "categoryId": "gcid:chicken_wings_restaurant"
  }, 
  "locationState": {
    "canUpdate": true, 
    "isGoogleUpdated": true, 
    "canDelete": true, 
    "isVerified": true
  }
}

while the GoogleUpdated call still shows the suggested attributes, despite patching that field to 4 attributes. https://mybusiness.googleapis.com/v3/accounts/113311880217305589942/locations/15066564058077106958:g...

  "diffMask": "attributes", 
  "location": {
    "storeCode": "108", 
    "additionalCategories": [
      {
        "name": "Restaurant", 
        "categoryId": "gcid:restaurant"
      }, 
      {
        "name": "Bar", 
        "categoryId": "gcid:bar"
      }, 
      {
        "name": "American Restaurant", 
        "categoryId": "gcid:american_restaurant"
      }, 
      {
        "name": "Cafe", 
        "categoryId": "gcid:cafe"
      }
    ], 
    "openInfo": {
      "status": "OPEN"
    }, 
    "name": "accounts/113311880217305589942/locations/15066564058077106958", 
    "locationKey": {
      "plusPageId": "100659650070891935246", 
      "placeId": "ChIJwR_6w0yI-4gRyC4TibgL0I4"
    }, 
    "specialHours": {
      "specialHourPeriods": [
        {
          "startDate": {
            "month": 12, 
            "day": 24, 
            "year": 2015
          }, 
          "openTime": "00:00", 
          "endDate": {
            "month": 12, 
            "day": 24, 
            "year": 2015
          }, 
          "closeTime": "18:00"
        }
      ]
    }, 
    "adWordsLocationExtensions": {}, 
    "metadata": {}, 
    "regularHours": {
      "periods": [
        {
          "openDay": "SUNDAY", 
          "closeDay": "SUNDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "SUNDAY", 
          "closeDay": "SUNDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }, 
        {
          "openDay": "MONDAY", 
          "closeDay": "MONDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "MONDAY", 
          "closeDay": "MONDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }, 
        {
          "openDay": "TUESDAY", 
          "closeDay": "TUESDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "TUESDAY", 
          "closeDay": "TUESDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }, 
        {
          "openDay": "WEDNESDAY", 
          "closeDay": "WEDNESDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "WEDNESDAY", 
          "closeDay": "WEDNESDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }, 
        {
          "openDay": "THURSDAY", 
          "closeDay": "THURSDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "THURSDAY", 
          "closeDay": "THURSDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }, 
        {
          "openDay": "FRIDAY", 
          "closeDay": "FRIDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "FRIDAY", 
          "closeDay": "FRIDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }, 
        {
          "openDay": "SATURDAY", 
          "closeDay": "SATURDAY", 
          "openTime": "00:00", 
          "closeTime": "02:00"
        }, 
        {
          "openDay": "SATURDAY", 
          "closeDay": "SATURDAY", 
          "openTime": "11:00", 
          "closeTime": "24:00"
        }
      ]
    }, 
    "locationName": "Wild Wing Cafe - Bluffton", 
    "photos": {
      "logoPhotoUrl": "https://lh3.googleusercontent.com/s5W7EyW_i0z_6Q6Qin4da1G9nb19-h8i7A4Gf8rkeY0zCOYSsKcAEOhhZH_VcVKt_3s=s0", 
      "profilePhotoUrl": "https://lh3.googleusercontent.com/Qis3hScwtGmLhmHV8vVCamzSL_J6eBNI2ACeuzDQnYZyIFIb6vt4RqQ6gPsjXXB1xGVyxduE=s0", 
      "coverPhotoUrl": "https://lh3.googleusercontent.com/X-0yFEr9_3QY1Xzw3iS0j7csZCOznw5UbcCdWtCwSybw2RlxdsQsbnIYDkGIlUy2row=fcrop64=1,00000c81ffff9ee4"
    }, 
    "primaryPhone": "(843) 837-9453", 
    "address": {
      "postalCode": "29910", 
      "country": "US", 
      "administrativeArea": "South Carolina", 
      "addressLines": [
        "1188 Fording Island Rd"
      ], 
      "locality": "Bluffton"
    }, 
    "websiteUrl": "http://www.wildwingcafe.com/locations/bluffton-sc", 
    "attributes": [
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_lunch"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_wine"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_dinner"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_beer"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "has_takeout"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "has_wi_fi"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "has_live_music"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_beer_craft"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_happy_hour"
      }, 
      {
        "values": [
          true
        ], 
        "valueType": "BOOL", 
        "attributeId": "serves_alcohol"
      }
    ], 
    "primaryCategory": {
      "name": "Chicken Wings Restaurant", 
      "categoryId": "gcid:chicken_wings_restaurant"
    }, 
    "locationState": {
      "canUpdate": true, 
      "isGoogleUpdated": true, 
      "canDelete": true, 
      "isVerified": true
    }
  }
}

Let me know if you need any other info.


Thanks,

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

[ Edited ]
Google Employee
# 6
Google Employee

Hi @Patrick L,

 

The additional attributes you're seeing in the GoogleUpdated call are working as intended. The complete list of attributes for a location are determined by its category, and will all always appear if set (either by you directly, or by Google through GoogleUpdated values). If you want to explicitly change these values, you should include them in your PATCH call, setting them to the desired value (true or false).

 

Hopefully this helps clear things up, but let us know if you have any additional questions.

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

Follower ✭ ✭ ☆
# 7
Follower ✭ ✭ ☆

Hi @Andrew H,

 

Thanks for the response. I guess I'm not understanding when values are dropped from the GoogleUpdated call.

 

I see that, if my regularHours field has a googleUpdated difmask, and then I patch the regularHours field, my hours are accepted and the difmask is dropped.

 

I have executed a googleUpdated call on the above location, took note of all the attributes and true false values present, and then patched those exact values back, (ie the attributes and true/false values in the Get call, and the GoogleUpdated call should now be the exact same).

 

Executing another googleUpdated call after the patch, attributes is still present in the difMask (meaning we have to run our own difs to ensure there actually are changes between our GMB object and what is live on Google).

 

Is there ever an instance where attributes will no longer trigger a difMask/googleUpdated flag? I had originally thought that sending a patch to a field drops that field from the difMask, up until Google surfaces additional updates for that field, which in turn would flag that field as updated again.

 

Thanks for your help on this.

 

Re: Updating Attributes Not Wiping Google Updated Values for Attributes

Google Employee
# 8
Google Employee

Hey @Patrick L,

 

How much time are you allowing between your PATCH call and re-checking the GoogleUpdated call? With attributes in-particular it may take several minutes for these to propagate through out system, clearing out these fields from the GoogleUpdated endpoint.