Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/csharp-4.0/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 无法在v3.0中使用Facebook API发布消息用户(自己的)时间线_Php_Laravel_Facebook_Api - Fatal编程技术网

Php 无法在v3.0中使用Facebook API发布消息用户(自己的)时间线

Php 无法在v3.0中使用Facebook API发布消息用户(自己的)时间线,php,laravel,facebook,api,Php,Laravel,Facebook,Api,V3.0 我想在v3.0中使用Facebook Graph API发布内容/消息,但无法发布消息,因为出现以下错误 { "error": { "message": "(#200) Requires either publish_actions permission, or manage_pages and publish_pages as an admin with sufficient administrative permission",

V3.0

我想在v3.0中使用Facebook Graph API发布内容/消息,但无法发布消息,因为出现以下错误

{
  "error": {
            "message": "(#200) Requires either publish_actions permission, or manage_pages and publish_pages as an admin with sufficient administrative permission",
            "type": "OAuthException",
            "code": 200,
            "fbtrace_id": "xxx"
          }
}
PHP代码:

try {
     // Returns a `FacebookFacebookResponse` object
     $response = $fb->post('/xxxxxxxxxxx3x02/feed', 
     array (
        'link' => 'test.com',
        'message' => 'Test'
     ),
    '{access-token}'
    );
} catch(FacebookExceptionsFacebookResponseException $e) {
    echo 'Graph returned an error: ' . $e->getMessage();
    exit;
} catch(FacebookExceptionsFacebookSDKException $e) {
    echo 'Facebook SDK returned an error: ' . $e->getMessage();
    exit;
}
$graphNode = $response->getGraphNode();
Facebook权限

在v3.0中,“发布操作”被删除


我们如何通过PHP SDK将消息发布到用户时间线?请注意?

作为旁注,PHP SDK文档中的大多数链接都是404。另外,sdk似乎还没有更新:也许你可以同时瞄准旧版本的v2 api?嗨,勒克,谢谢你的回复,当我尝试使用旧版本的Facebook api v2.10时。它在旧版本中似乎工作正常。新版本V3.0没有使用API发布在我自己的时间线中。有人建议我发布用户时间线需要哪个权限吗?“我们如何通过PHP SDK将消息发布到用户时间线中?”-你不能。如果Facebook希望你仍然能够这样做,他们一开始就不会删除该权限-呸!谢谢你的回复。