Home Error (#230) Permissions disallow message to user api Facebook
Reply: 0

Error (#230) Permissions disallow message to user api Facebook

Nidalc
1#
Nidalc Published in 2017-12-05 11:38:15Z

i have some problem with the open graph api when i try to send a message through the api.

Here is my code :

try {
        // Returns a `Facebook\FacebookResponse` object
        $response = $fb->post(
            '/' . $conversation_id . '/messages',
            array(
                'message' => $this->source['message'],
            ),
            $token_page
        );

        $this->loadModel("PageAccount");
        $currentPage = $this->PageAccount->findById($this->source['page_id']);

        $token = $this->source['token'];
        $data = file_get_contents("https://graph.facebook.com/v2.9/" . $this->source['conversation_id'] . "?access_token=$token&fields=messages.limit(200){message,created_time,to,from}");
        $data = json_decode($data, 1);

        $view = new View($this, false);
        $element = $view->element("admin/conversations/all-conversation", array("conversation" => $data));

        return $this->getSuccessResult(array("conversation" => $element));

    } catch (Facebook\Exceptions\FacebookResponseException $e) {
        return $this->getErrorResult("Une erreur est survenue");
    }

The error that Facebook send me : (#230) Permissions disallow message to user

Thanks for your help :)

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.300813 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO