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

Open access to Facebook Video in Graph API has been removed #1

Open
joshmcarthur opened this issue Mar 6, 2018 · 0 comments
Open

Comments

@joshmcarthur
Copy link

Hello,

First of all, thanks for creating this module. It's working fantastically for all of the YouTube and Vimeo URLs I can throw at it.

While testing a Facebook video, I noticed that Facebook was responding with a 400 HTTP status, with the body:

{
   "error": {
      "message": "An access token is required to request this resource.",
      "type": "OAuthException",
      "code": 104,
      "fbtrace_id": "Bw9VfcjGWS8"
   }
}

I researched the Graph API documentation for the Video type, and found that at least from Graph API version 2.5 (maybe further back, but I can't find documentation older than v2.5), an access token is required to read any video data at all.

I realise that there is a test asserting that a Facebook URL returns the expected thumbnail image, but I note that Travis has not done a build for 2 years. I suspect that running the tests today would cause this test to fail, demonstrating the issue I have described here.

I would be happy to submit a pull request to try and resolve this issue, but would appreciate a little guidance. According to a StackOverflow post, adding /picture to the URL will return a thumbnail image of the video, however I can only get this to work for videos on pages (https://graph.facebook.com/1393626100686564/picture), not user videos (https://graph.facebook.com/10206649655735422/picture - returns error response). Additionally, the picture that is returned is quite small - possibly too small even for thumbnail use.

The other option would be to allow an access token to be passed in to some kind of configuration object within this library. I have concerns about this though, as access tokens are sensitive, and given this library seems intended for mostly frontend use, I am not sure that it is the kind of configuration that should be encouraged to be pushed into front-end Javascript.

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

1 participant