Upload Video to Facebook Wall

Jul 12, 2009 at 7:10 PM

I am developing an application that will automatically post videos the user makes to their Wall.  At this point, I have obtained extended permissions for publish_streams, read_streams and offline_access (it takes some time to create and render the video after the user is done, or they can call our 800 number to create another video).  When the video is completed I upload it to the user's video.

I cannot figure out how to have this video published so it appears on their Wall.  To accomplish this, I have not used the stream.publish or feed.publishUserActon commands. Do I need to use these, use a feed template or add something else to my application?  Or is it a matter of gaining Facebook approval for the application?

Any help will be much appreciated.

peterdolson

 

Jul 30, 2009 at 12:11 PM

Hi,

I am trying to do exactly the same thing. Did you find a solution?

Jul 30, 2009 at 12:11 PM

Hi,

I am trying to do exactly the same thing. Did you find a solution?

Jul 30, 2009 at 4:05 PM

Facebook now has individual emails that can be used to post to the walls. We are using that at the moment. I know there is a solution by uploading video and then posting to wall, but I am operating in .NET with c# and do not want to reprogram everything for FBML or php. I believe the approach I was taking (getting the extended permissions, etc.) would be correct. I only needed to finish posting the video to the wall. I was attempting to do that even if the video post to the wall was not there, and that might not be possible.

Peter

Peter D. Olson

peterdolson@sbcglobal.net

209-834-0008 Office

831-428-2977 Mobile


From: mebibou [mailto:notifications@codeplex.com]
Sent: Thursday, July 30, 2009 5:11 AM
To: peterdolson@sbcglobal.net
Subject: Re: Upload Video to Facebook Wall [FacebookToolkit:62232]

From: mebibou

Hi,

I am trying to do exactly the same thing. Did you find a solution?

Read the full discussion online.

To add a post to this discussion, reply to this email (FacebookToolkit@discussions.codeplex.com)

To start a new discussion for this project, email FacebookToolkit@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Jul 30, 2009 at 5:14 PM

This should work -

public void publishTest4()
        {
            API parent = _api;
            stream target = _api.stream;
            attachment attachment = new attachment();

            attachment.caption = "www.youtube.com";
            attachment.name = "ninja cat";
            attachment.href = "http://www.youtube.com/watch?v=muLIPWjks_M";
            attachment.description = "a sneaky cat";
            attachment.properties = new attachment_property()
            {
                category = new attachment_category()
                {
                    href = "http://www.youtube.com/browse?s=mp&t=t&c=15",
                    text = "pets"
                },
                ratings = "5 stars"
            };
            attachment.media = new List<attachment_media>(){new attachment_media_video()
                                    {
                                        video_src = "http://www.youtube.com/v/fzzjgBAaWZw&hl=en&fs=1",
                                        preview_img="http://img.youtube.com/vi/muLIPWjks_M/default.jpg?h=100&w=200&sigh=__wsYqEz4uZUOvBIb8g-wljxpfc3Q=",
                                        video_link = "http://www.youtube.com/watch?v=muLIPWjks_M",
                                        video_title = "ninja cat"
                                    }};
            var link = new action_link();
            link.href = "http://www.youtube.com/my_videos_upload";
            link.text = "Upload a video";

            var links = new List<action_link>() { link };
            var actual = target.publish("Watch this video!", attachment, links, null, 0);
            Assert.IsNotNull(actual);
        }
Jul 31, 2009 at 4:30 AM

Hum yeah well this is working with Youtube but not really with your own web page! because how could facebook play a video that you are hosting on your web site?

With Youtube it's easy because they provide the right player ...

So what I just did is to publish just a photo on the wall, and then when the user click on it he's redirected to my page where the video can be played. Thanks for your replys