开发者

Facebook Graph API - "Related Post" in status update

开发者 https://www.devze.com 2023-03-11 00:03 出处:网络
In the Facebook UI, you can hit \"@\" when you update your status and get a list of pages where your status update will be added as a Related Post on the page.

In the Facebook UI, you can hit "@" when you update your status and get a list of pages where your status update will be added as a Related Post on the page.

Is there a way to do the same in the Graph API? Assuming all authenticated, calling me/feed with a "message" parameter like this (using .NET Facebook SDK):

var client = new FacebookClient(ACCESS_TOKEN);
var parms = new Dictionary<string, object>();
parms.Add("message", "开发者_StackOverflowTEST fb SDK: @whatever");
client.Post("me/feed", parms);

The status update is posted, but the page doesn't doesn't get resolved as a Related Post.

If you GET a feed entry which has a Related Post created from the UI it's shown as a status update with the "to" parameter populated with the page. If you recreate that message as a POST in the API, the Related Post gets created, but:

  • the Related Post shows on the Info tab of the page, not the Related Posts tab
  • the status update doesn't have a link to the Related Post

Any thoughts? Thanks!


Someone has posted an undocumented way of tagging users using Facebook Graph API that involves using a @[{user_id}:1:{name}] syntax, eg: @[{4}:1:{Mark Zuckerberg}]. There is an open request with Facebook for full documented support of this method.

0

精彩评论

暂无评论...
验证码 换一张
取 消