How can I post a video, via Facebook's Connect API, to my Facebook profile page?

11,278

Solution 1

Use the Video.upload as described by stevedbrown or the Stream API or if you want to go simple share the link via API or share link.

Solution 2

The question may have not been correctly worded. The term "API" was misleading to a couple of folks - and I apologize for that.

What I was trying to do was to "share" a video by linking it in Facebook, AND to have it play in the profile feed (ie. to not leave the Facebook site while viewing the video - just like YouTube and Hulu.com do).

After digging into the JavaScript that Hulu was using to get this behavior, we noticed that a link tag was missing between our version of the <meta> and <link> tags, and Hulu's.

Facebook's web page, http://www.facebook.com/share_partners.php, was missing a tag that you should have if the content is a video, and you want it played in the profile feed.

Along with:

<link rel="video_src" href="http://www.example.com/player.swf?video_id=123456789"/> ...

You should include:

<link rel="media:video" href="http://www.example.com/player.swf?video_id=123456789"/>  

That will get it to play in the feed. BUT, your domain name must be whitelisted.

To get your domain whitelisted, fill out this form: http://www.facebook.com/share_partners.php#/developers/developer_help.php

I got a reply, and approval, within a day! Kudos to the Facebook developer support staff!

Share:
11,278
Aki Iskandar
Author by

Aki Iskandar

Updated on June 05, 2022

Comments

  • Aki Iskandar
    Aki Iskandar almost 2 years

    Has anyone posted a video via the Facebook Connect API to their profile / feed page?

    Ideally, the video should be queued to the first frame with the superimposed Facebook's blue right arrow "play" button. Or if a thumbnail representing the video has to also be uploaded (rather than the video being queued to the first frame) as well, this is fine.

    Also, when the video, or thumbnail, on the profile page is clicked, the video plays where it is - rather than going to another page off Facebook to be played there.

  • Aki Iskandar
    Aki Iskandar almost 15 years
    Thanks Andreas. For the short term, we're trying to stay clear of using Facebook API's such as Video.upload, or even their new Connect API / platform. Using the share link is EXACTLY what we are trying to do - but we're having issues. We've read Facebook's partner share page: facebook.com/share_partners.php, and it seems straight forward enough. We have all the meta and link tags they require for a video, but there are two issues we can't seem to resolve: 1 - the video does not play embedded (your taken to an external page) 2 - the white/blue play arrow is not there Any ideas? .
  • Andreas Klinger
    Andreas Klinger almost 15 years
    shared pages (including a videoplayer) only show your videoplayer in the stream if your domain is whitelisted by facebook (hit support up for that). otherwise try to share the flv file in video_src
  • Aki Iskandar
    Aki Iskandar almost 15 years
    You are correct. The domain name has to be whitelisted by facebook. Also, the real issue was the documentation on the page facebook.com/share_partners.php ... there was a tag ommission. I will post an answer (using the "Answer Your Question" button) this for other people that may be going through the same issue.