好的,这有点取巧,但我看不到其他方法。在你的新闻订阅中,你会看到一条类似于以下内容的项目:
{
"id": "123456789_3453453455345334",
"from": {
"name": "A Friend",
"id": "123456789"
},
"to": {
"data": [
{
"name": "A Friend",
"id": "123456789"
}
]
},
"picture": "PICTURE_URL",
"link": "http://www.facebook.com/photo.php?fbid=3453453455345334&set=a.10151233554845639.123456.123456789&type=1",
"name": "Mobile Uploads",
"caption": "10 new photos",
"icon": "ICON_URL",
"type": "photo",
"object_id": "3453453455345334",
"application": {
"name": "Facebook for iPhone",
"id": "6628568379"
},
"created_time": "2000-06-29T19:56:50+0000",
"updated_time": "2001-06-29T19:56:50+0000"
},
关键在于链接URL中包含的内容:
set=a.10151233554845639.123456.123456789
在a后面的第一个数字似乎是专辑ID。因此,我们可以通过查询来获取专辑中的照片:
https://graph.facebook.com/10151233554845345/photos?access_token=ACCESS_TOKEN
如果您分享的照片已经存在于Facebook上,则会出现一个名为“属性”的额外属性:
"properties": [
{
"name": "By",
"text": "A Friend",
"href": "http://www.facebook.com/a.friend"
}
],
如果您在您的墙上分享一张照片,这实际上是一个上传操作,因此将不包括“properties”属性。