Search code examples
google-api-js-clientgoogle-people-api

how to update 'people/me'


i use

people.get({resourceName: 'people/me'})

get logged-in user's info, but i can't use

people.updateContact({resourceName: 'people/me', ...})

or

people.updateContact({resourceName: 'people/[meid]', ...})

update this info.

error message is :

{code: 400, message: "Resource name "people/me" is not a valid contact person resource.", status: "INVALID_ARGUMENT"}

or

{code: 400, message: "Resource name "people/[meid]" is not a valid contact person resource.", status: "INVALID_ARGUMENT"}

Solution

  • There isn't support for updating the people/me resource in the Google People API as the API only supports updating contacts, and people/me represents the person based on your profile / account. There's some info describing how merged people are composed at https://developers.google.com/people/#understanding_merged_person_data. Only contact based people can be updated.