I want to post a video on Facebook via AS3 Graph API. I'm not able to do it. Im only able to post the photo. Is it possible to post flv or youtube link using AS3 Graph API?
Asked
Active
Viewed 723 times
2 Answers
0
To Upload video check below code.
if you want flv convert to byteArray fast. read a this article: flv encoder alchemy
function uploadVideo(ba:ByteArray)
{
var videoObj:Object=new Object();
videoObj.title = "My Video Title";
videoObj.description = "My Video Description";
videoObj.fileName ="myVideo.flv"
videoObj.video = ba;
Facebook.uploadVideo("/me/videos",videoUploaded,videoObj);
}
function videoUploaded(response:Object,fail:Object)
{
if(response)
{
trace("success");
}
if(fail)
{
trace("failed");
}
}
Posting an Youtube video link.
check this: Posting an embedded video link using the Facebook Graph API

Community
- 1
- 1

bitmapdata.com
- 9,572
- 5
- 35
- 43
0
I am also facing the same problem. @bitmapdata.com I want to Post the Feed and I am using following code
function newsFeed ():void
{
var theCaption:String = user.Name+" Shared this Video ";
var theDescription:String = user.Name+" become a star.";
var methodInput:String = 'feed';
var thePicture:String = "http://xyz.com/logo.png";
var theLink:String = this.flvPath;
var theSource:String = this.flvPath,
var theName:String = "Star Post";
var data:Object = {
caption:theCaption,
description:theDescription,
picture:thePicture,
source:theSource,
name:theName,
link:theLink
};
Facebook.ui(methodInput, data, onUICallback);
}
Its posting the post but its not showing video on facebook. when you click on post title or image it will download you video. i want to post the video on user wall so friends can see the video.