我正在使用这个Facebook API
POST https://graph.facebook.com/page-id/feed
我得到了这个错误。
"message": "(#200) Requires either publish_to_groups permission and app being installed in the group, or manage_pages and publish_pages as an admin with sufficient administrative permission",
"type": "OAuthException",
"code": 200,
"fbtrace_id": "EHBzoSb+sr1"
答案 0 :(得分:0)
由于要发布到页面,因此请根据注释:必须具有 @using (Html.BeginForm("EditAttorney", "Admin", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
@Html.AntiForgeryToken()
<div class="form-body">
<div class="form-group">
<label>Detaylı Açıklama(kullanıcı için)</label>
<div class="input-group col-md-9">
<textarea class="ckeditor form-control" name="AttorneyDescription" id="AttorneyDescription" rows="6" data-error-container="#editor2_error"> @Html.Raw(Model.AttorneyDescription)</textarea>
</div>
</div>
<div class="row">
<div class="col-md-4">
<div class="fileinput fileinput-new" data-provides="fileinput">
<div class="fileinput-new thumbnail" style="width: 200px; height: 150px;">
<img src="https://www.placehold.it/200x150/EFEFEF/AAAAAA&text=no+image" alt="" />
</div>
<div class="fileinput-preview fileinput-exists thumbnail" style="max-width: 200px; max-height: 150px;"> </div>
<div>
<span class="btn default btn-file">
<span class="fileinput-new"> Resim Seç</span>
<span class="fileinput-exists"> Değiştir </span>
<input type="file" name="imageFile" id="imageFile" accept="image/*">
</span>
<a href="javascript:;" class="btn red fileinput-exists" data-dismiss="fileinput"> Sil </a>
</div>
</div>
</div>
<div class="col-md-offset-1 col-md-4">
@if (ViewBag.AttorneyImage != null)
{
<a class="example-image-link" href="@Url.Content(ViewBag.AttorneyImage)" data-lightbox="example-1"><img class="example-image" src="@Url.Content(ViewBag.AttorneyImage)" alt="image-1" width="230" /></a>
}
</div>
</div>
</div>
<div class="form-actions">
<button type="submit" class="btn blue">Güncelle</button>
<button type="button" class="btn default" onclick="location.href='@Url.Action("ListOfAttorney","Admin")'">İptal</button>
</div>
}
权限的页面令牌才能发布到页面。现在,您可能正在尝试使用用户令牌进行呼叫。届时publish_pages
将成为用户。