Google Contacts Api Getting contacts in a certain group. (The my contacts group)

大城市里の小女人 提交于 2020-01-02 10:16:15

问题


So I can get all my contacts with this:

https://www.google.com/m8/feeds/contacts/default/full?access_token=mytoken&alt=json&v=3

And all my groups with this:

https://www.google.com/m8/feeds/groups/default/full?access_token=myToken&alt=json&v=3    

And I can get the actual contact group for "myContacts" with this:

https://www.google.com/m8/feeds/groups/default/base/6?access_token=mytoken&alt=json&v=3

But how can I get all the contacts in the myContacts group? The previous query just gives me the actual group.


回答1:


You can use the below URI in order to get the contacts of a specific group.

href="http://www.google.com/feeds/contacts/groups/userEmail/base/1234b"/

For reference and more information check the documentation of the Google Contacts API here in the Retrieving contacts using query parameters section.

The query parameters (including the group of course) that you may use are listed here in the Contacts query parameters reference.




回答2:


Your request - https://www.google.com/m8/feeds/contacts/default/full?access_token=mytoken&alt=json&v=3

Group id - http://www.google.com/feeds/contacts/groups/userEmail/base/1234b

Then call to GET contacts of group

https://www.google.com/m8/feeds/contacts/default/full?access_token=mytoken&alt=json&v=3&group=http://www.google.com/feeds/groups/userEmail/base/1234b


来源:https://stackoverflow.com/questions/30359085/google-contacts-api-getting-contacts-in-a-certain-group-the-my-contacts-group

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!