This is probably a basic scripting question but I have limited coding experience and most solutions I have find around this refer to HTML calls via JSON. I am trying to do this via apps script...

I have sucessfully coded to draw the relevant info from Google Sheets and create individiual contacts. I also have code to update the CoverPic but to do this I need to get the "resourceName" (person.id) from the response body created by the Method: people.createContact

I have read that if the creation of the contact is sucessful the the response body contains an instance of Person.

The closest answer I have found is here. But this addresses the problem of getting the responseBody via a JSON parse which in turn is derived from a URL call.

If I understand correctly, the response body includes the "resourceName" as a string but I don't have the knowledge of how to access this via Apps scipt.

Any help is appreciated.

0

There are 0 best solutions below