请求加入Facebook Graph API组 [英] Request join a group for Facebook Graph API
问题描述
我在此图表中的请求很好:
v2.3 / 402998003100416 / feed?message = hello
返回是这样的:
{
error:{
message:权限错误,
type:FacebookApiException,
code:200,
error_subcode:1376025,
is_transient :false,
error_user_title:无权限发布,
error_user_msg:您没有权限在此组中发布。
}
}
显然,问题是该组的隐私是关闭我只能发表,如果它是一个成员,但我没有要求参加该组。我的意图正是这样,使用图表提交加入组的请求,像点击+组加入Facebook按钮本身。如何做?
利用相同的方式,我想知道我是否可以享受图api的一个粉丝页面。
应用程序只能邀请用户访问该应用程序创建的组,您可以在文档中阅读: https://developers.facebook.com/docs/graph-api/reference/v2.3/group/members#发布
无法使用API向普通组发送请求或邀请。
要在组中创建一个帖子,您需要 publish_actions
和 user_groups
: https://developers.facebook.com/docs/graph-api/reference/v2 .3 / group / feed#publish
请记住,你很可能不会得到 user_groups
批准:
这种权限被授予在Facebook尚未提供的平台上构建Facebook品牌客户端
的应用程序。例如,
Android和iOS应用将不被批准用于此权限。在
的另外,Web,桌面,车载和电视应用程序不会被授予这个
权限。
https://developers.facebook.com/docs/ Facebook-login / permissions / v2.3#reference-user_groups
编辑:Facebook最近发布了新的权限 user_managed_groups
用于访问用户是管理员的组。
We developed a system which interacts with Facebook using the Graph API. In this case, I am trying to post a message in a group and I am with the following return:
My request in this Graph well:
v2.3/402998003100416/feed?message=hello
And the return is this:
{
"error": {
"message": "Permissions error",
"type": "FacebookApiException",
"code": 200,
"error_subcode": 1376025,
"is_transient": false,
"error_user_title": "No Permission to Post",
"error_user_msg": "You do not have permission to post in this group."
}
}
Obviously the problem is that the group's privacy is "closed" and I could only publish if it were a member, but I have not asked to participate in the group. My intention is precisely this, use the Graph to submit a request to join the group, something like clicking the "+ Group Join" facebook button itself. How to do it?
Leveraging the same way, I wonder if I can enjoy one fan page for the graph api.
Apps can only invite users to a group created by that App, as you can read in the docs: https://developers.facebook.com/docs/graph-api/reference/v2.3/group/members#publish
It is NOT possible to send requests or invites to normal groups with the API.
For creating a post in a group, you would need publish_actions
and user_groups
: https://developers.facebook.com/docs/graph-api/reference/v2.3/group/feed#publish
Keep in mind that you will most likely not get user_groups
approved:
This permission is granted to apps building a Facebook-branded client on platforms where Facebook is not already available. For example, Android and iOS apps will not be approved for this permission. In addition, Web, Desktop, in-car and TV apps will not be granted this permission.
https://developers.facebook.com/docs/facebook-login/permissions/v2.3#reference-user_groups
Edit: Facebook recently released a new permission user_managed_groups
for accessing groups the user is an admin of.
这篇关于请求加入Facebook Graph API组的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!