简体   繁体   中英

Facebook Graph API Video Upload Permissions

I'm working on an application that integrates w/ Facebook to publish videos that are then displayed on our app outside of FB.

We have a Facebook page for the app, and uploading/posting via the FB Graph API (PHP) to the FB Page's stream/timeline/album works fantastically as it uploads the video, sets privacy to public, and posts a story to the timeline. (I have tested non-page admins posting via the App's test users. All good.)

However, what we would like to do is post to the users' albums from the app, and explicitly set privacy for that video such that the video can be accessed via our application to be displayed in our app outside of Facebook.

Currently, if I post to my own profile (using a POST request to /me/videos; I am listed as an App admin), the video is uploaded as expected but privacy for the video is set to 'Only Me', and I cannot access the video via the Graph API to be displayed on the website.

Is it possible to do what I want here? Below is the basic code I am using to upload to the user's profile:

$this->facebook->setFileUploadSupport(true);

$upload = $this->facebook->api('/me/videos', 'POST', array(
    'source' => '@'.$file,
    'title' => $title,
    'description' => $description,
    'privacy' => json_encode(array( 'value' => 'EVERYONE' ))
));

As you can see, I'm attempting to set the privacy via the 'privacy' parameter (omgrly?). This does not appear to set the privacy as expected (?).

Thank you in advance for your help!

EDIT: I understand this default maximum permission is set at the time the app is first authenticated. What I would like to know is if these privacy settings can be altered on a per-post basis.

根据我的发现,与在Facebook Connect身份验证对话框中选择的值相比,不能将单个帖子的隐私值提高到“更公开”的程度。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM