如何使用Facebook Graph API分享一个人的帖子 [英] How to share someone's post using Facebook Graph API
本文介绍了如何使用Facebook Graph API分享一个人的帖子的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
解决方案
是的,您可以使用graph2 api共享。您的方法是使用 / feed
edge,并将要共享的帖子的URL传递给该链接。
POST /v2.2/{page-id}/feed HTTP / 1.1
主机:graph.facebook.com
link = https ://www.facebook.com/ {page_id} / posts / {post_id}
标准Fb权限对于您正在分享的信息,请适用。
My Facebook App posts messages on user wall. I want to share this messages on my wall, same as I click share action under user message. How can I do it using Facebook Graph API?
解决方案
Yes, you can share using the graph2 api. The way you do it is to use /feed
edge and pass the post's url that you want to share as the link.
POST /v2.2/{page-id}/feed HTTP/1.1
Host: graph.facebook.com
link=https://www.facebook.com/{page_id}/posts/{post_id}
Standard Fb permissions to the post you are sharing do apply.
https://developers.facebook.com/docs/graph-api/reference/v2.2/page/feed
This was done today, in a local rails app, using FbGraph2 gem, with the above method.
这篇关于如何使用Facebook Graph API分享一个人的帖子的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文