如何获取用户或页面的Google Plus相册?我可以一起获得活动(帖子/视频/照片)。Google Plus API获取相册/视频
这是我使用的代码:
var provider = new NativeApplicationClient(GoogleAuthenticationServer.Description);
provider.ClientIdentifier = GoogleIdentifier;
provider.ClientSecret = GoogleSecret;
ActivitiesResource.Collection collection = new ActivitiesResource.Collection();
var service = new PlusService();
service.Key = GoogleKey;
ActivitiesResource.ListRequest list = service.Activities.List(ProfileID, collection);
foreach (Activity activityFeed in list.Fetch().Items)
{
var title = activityFeed.Title;
foreach (Activity.ObjectData.AttachmentsData attachment in activityFeed.Object.Attachments)
{
if (attachment.ObjectType == "photo")
{
//add to list of photo
}
else if (attachment.ObjectType == "video")
{
//add to list of video
}
}
}
这个功能可以使活动源。我需要获得一个页面的所有专辑列表。我正在使用google-api-dotnet-client。
你能告诉我们你到目前为止所尝试过的吗? – Surfbutler 2012-07-07 08:20:50
这是我现在使用的代码..我已经发布了另一个问题。因为我在fetch()函数中有错误。 [链接](http://stackoverflow.com/questions/11370362/an-item-with-the-same-key-has-already-been-added-google-plus)@Surfbutler – MMALSELEK 2012-07-07 08:48:13