标记了我的专页的帖子不会显示在API调用中 [英] Posts that have tagged my Page don't show up with API call
问题描述
我为我的服务此处创建了一个Facebook专页.该页面的名称是Rowz.
I have a Facebook Page created for my service here. The name of the page is Rowz.
用户在页面上有一些帖子,他们在自己墙上的帖子中标记了该页面.这些帖子显示在Rowz Page时间轴上.在Graph API for Page中,有一个已标记"字段,我认为该字段会向我发送这些帖子,但同样行不通.
There are some posts on the page by users who have tagged the Page in posts on their own walls. Those posts show up on the Rowz Page timeline. In the Graph API for Page there is a field 'tagged' which I assumed would get me these posts but the same doesn't work.
有没有办法获取那些在其中标记了Rowz的帖子?
Is there a way to fetch those posts that have tagged Rowz in them?
推荐答案
根据图形API中页面对象的文档,tagged
连接可为您提供所需的结果:
According to the documentation for page object in graph API, tagged
connection gets you the required result:
名称:
tagged
描述:Page
所在的照片,视频和帖子
权限:任何有效的access_token
或用户access_token
.
返回:Photo
,Video
或Photo
的异构array
Post
对象.
name:
tagged
description: The photos, videos, and posts in which thePage
has been tagged.
permission: any validaccess_token
or useraccess_token
.
returns: a heterogeneousarray
ofPhoto
,Video
orPost
objects.
您可以在此处使用图形API资源管理器(使用问题中提到的页面ID)对其进行测试:
You can test it here using graph API explorer (using the page ID mentioned in the question): https://developers.facebook.com/tools/explorer/?method=GET&path=265813166783408%2Ftagged
对我来说很好.
您也可以考虑使用FQL.使用类似这样的查询来查询 stream_tag 表:
You may also consider using FQL for it. Query stream_tag table using a query something like this:
SELECT post_id,actor_id FROM stream_tag WHERE target_id=265813166783408
此后,您可以遍历post_id
并在stream
表中查询message
字段.
After this, you can iterate over post_id
and query stream
table for message
field.
这篇关于标记了我的专页的帖子不会显示在API调用中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!