问题
I'm pulling a user's contacts email addresses and names using the Google Contacts API. Is there a way to get those people's Google+ IDs as well?
回答1:
The contacts API will return a profile
link if a G+ profile is linked with the contact entry.
Here's an example:
<gContact:website href='http://www.google.com/profiles/1234567890' rel='profile'/>
In that element's href
attribute, 1234567890
is the person identifier that would match the id
field of the relevant person resource from people.list
of the Google+ People API.
Note that the profile
link is not guaranteed to come back for a contact entry. This occurs when the contact has not been linked to a Google+ profile.
来源:https://stackoverflow.com/questions/15802267/get-google-id-from-google-contacts