I want to embed facebook
videos to my android
app. Is there any API
for that? I checked for facebook API
but it seems it is only for web. If there is no good API, what should I use? WebView
or VideoView
or anything else?
Question posted in Facebook API
The official documentation for the Facebook APIs can be found here.
The official documentation for the Facebook APIs can be found here.
2
Answers
I was able to play facebook video by loading this url within webview. But it has some issue for example, can not resize video, can not fully use player control.
“https://www.facebook.com/video/embed?video_id=video_id/“
I know this is an old question, but the appropriate way to do this would be to serve up a page from a server that loads the Facebook embedded player. You can find the answer on Facebooks developer platform docs. Search for "Embedded Video & Live Video Player". A working link as of right now is here.
Here’s the example code snippet that Facebook provide:
It works quite well, but it should be accessed with https as this seems to be a requirement to use the Facebook APIs.
[Edit] Just for extra information. Between the Android webview and Facebook player this is plenty configurable to allow to display the videos as you want.