Google 联系人 API 学习是联系人 google+ 还是不是
Google Contacts API learn is contact google+ or not
我正在使用 Google 联系人 API 在我的 NodeJS 应用程序中获取用户的联系人,我需要检查是否有联系人 google+,但我不能在文档中找到一种方法。目前我收到来自 API 的回复,看起来像这样:
{ id: { '$t': 'http://www.google.com/m8/feeds/contacts/ex%40domain.com/base/40411dcf8aeb5354' },
updated: { '$t': '2016-08-12T08:03:22.026Z' },
category:
[ { scheme: 'http://schemas.google.com/g/2005#kind',
term: 'http://schemas.google.com/contact/2008#contact' } ],
title: { type: 'text', '$t': 'TestGoogleContact' },
link:
[ { rel: 'http://schemas.google.com/contacts/2008/rel#edit-photo',
type: 'image/*',
href: 'https://www.google.com/m8/feeds/photos/media/ii%40risingapp.com/40411dcf8aeb5354/1B2M2Y8AsgTpgAmY7PhCfg' },
{ rel: 'self',
type: 'application/atom+xml',
href: 'https://www.google.com/m8/feeds/contacts/ii%40risingapp.com/full/40411dcf8aeb5354' },
{ rel: 'edit',
type: 'application/atom+xml',
href: 'https://www.google.com/m8/feeds/contacts/ii%40risingapp.com/full/40411dcf8aeb5354/1470989002026004' } ],
'gd$email':
[ { address: 'testcontact@somedomain.com',
primary: 'true',
rel: 'http://schemas.google.com/g/2005#home' } ] }
联系人 API 早于 Google+,因此个人资料信息不可用。后来添加了一项功能,如果用户设置了个人资料中的 G+ 照片,则仅显示个人资料中的照片,这可能是检查个人资料的 hacky/flakey 启发式方法。但是,您可以通过使用人员 API 轻松获取此信息,它将 G+ 个人资料信息加入到联系人中,最终可能会替换联系人 API:https://developers.google.com/people/
我正在使用 Google 联系人 API 在我的 NodeJS 应用程序中获取用户的联系人,我需要检查是否有联系人 google+,但我不能在文档中找到一种方法。目前我收到来自 API 的回复,看起来像这样:
{ id: { '$t': 'http://www.google.com/m8/feeds/contacts/ex%40domain.com/base/40411dcf8aeb5354' },
updated: { '$t': '2016-08-12T08:03:22.026Z' },
category:
[ { scheme: 'http://schemas.google.com/g/2005#kind',
term: 'http://schemas.google.com/contact/2008#contact' } ],
title: { type: 'text', '$t': 'TestGoogleContact' },
link:
[ { rel: 'http://schemas.google.com/contacts/2008/rel#edit-photo',
type: 'image/*',
href: 'https://www.google.com/m8/feeds/photos/media/ii%40risingapp.com/40411dcf8aeb5354/1B2M2Y8AsgTpgAmY7PhCfg' },
{ rel: 'self',
type: 'application/atom+xml',
href: 'https://www.google.com/m8/feeds/contacts/ii%40risingapp.com/full/40411dcf8aeb5354' },
{ rel: 'edit',
type: 'application/atom+xml',
href: 'https://www.google.com/m8/feeds/contacts/ii%40risingapp.com/full/40411dcf8aeb5354/1470989002026004' } ],
'gd$email':
[ { address: 'testcontact@somedomain.com',
primary: 'true',
rel: 'http://schemas.google.com/g/2005#home' } ] }
联系人 API 早于 Google+,因此个人资料信息不可用。后来添加了一项功能,如果用户设置了个人资料中的 G+ 照片,则仅显示个人资料中的照片,这可能是检查个人资料的 hacky/flakey 启发式方法。但是,您可以通过使用人员 API 轻松获取此信息,它将 G+ 个人资料信息加入到联系人中,最终可能会替换联系人 API:https://developers.google.com/people/