Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Facebook: Graph returned an error: Unknown path components: /me/photos #14

Open
SagarNaliyapara opened this issue May 16, 2018 · 3 comments

Comments

@SagarNaliyapara
Copy link
Collaborator

SagarNaliyapara commented May 16, 2018

larasap.php

<?php

return [

    'facebook' => [
        'app_id' => '***',
        'app_secret' => '***',
        'default_graph_version' => '3.0',
        'page_access_token' => '***'
    ]

];

Code:

        SendTo::Facebook(
            'photo',
            [
                'photo' => 'image_path',
                'message' => 'Test message'
            ]
        );

It returns,

Graph returned an error: Unknown path components: /me/photos

What's the problem here?

@SagarNaliyapara SagarNaliyapara changed the title Graph returned an error: Unknown path components: /me/photos Facebook: Graph returned an error: Unknown path components: /me/photos May 16, 2018
@alihesari
Copy link
Owner

alihesari commented May 16, 2018

@SagarNaliyapara What is image_path. Basically, you should put your image file in public folder and use public_path() function. example:

SendTo::Facebook(
   'photo',
   [
       'photo' => public_path('image.jpg'),
       'message' => 'Laravel social auto posting'
   ]
);

@SagarNaliyapara
Copy link
Collaborator Author

@alihesari I've done the same but getting same error 😕

@neangkakada
Copy link

neangkakada commented Dec 30, 2020

I sovled it by add v char into the version,
'default_graph_version' => '3.0', => 'default_graph_version' => 'v3.0',

https://gitmemory.com/issue/alihesari/laravel-social-auto-posting/8/471250106

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants