How to get extended permissions for Flash Facebook API!

how to get facebook profile picture

This tutorial is going to teach you how to get the logged in user’s profile picture and post to their wall.

Thanks to Adobe’s Flex Examples, much of the code is used from their samples. I would also like to thank for their tutorial on using the Facebook Graph API. I used their tutorial as a starting point, and used Adobe’s examples as references to take it to the next level.

For this tutorial, I only used the least amount of coded needed to do the 3 objections.

Here is the Facebook API that I’ve used:

Facebook Samples from Adobe:

Graphi API Reference:

You will need to make these files to make it work.

Flash Facebook App, Post to wall

Click image to view the app!

extended permissions for flash facebook api

Here is a snippet of the code:

import com.facebook.graph.Facebook;

Extended Permissions
In the index.php file, in the Javscript redirect() function, go the the top.location line of code. After &scope=, insert the extended permission that you want.

For example:
publish_stream, create_event, rsvp_event, sms, offline_access, manage_pages, email, read_insights, read_stream, read_mailbox, ads_management, xmpp_login, user_about_me, user_activities, user_birthday, user_education_history, user_events, user_groups, user_hometown, user_interests, user_likes, user_location, user_notes, user_online_presence, user_photo_video_tags, user_photos, user_relationships, user_religion_politics, user_status, user_videos, user_website, user_work_history, email,publish_stream,offline_access,read_stream

In your Flash app, instead of using Facebook.login(callbackhandler);
use:“redirect”,”THE APPLICATION ID”, “user_birthday,read_stream,publish_stream”,” CANVAS PAGE/”);

Here is the site that I found out about the ExternalInterface call.

To get the user’s info
Facebook.api(‘/me/’, userInfo);

function userInfo(response:Object, fail:Object){
nameTextField.text =;

To get the user’s profile picture, you need to do a load from a url similar to this:”+id+”/picture”.

Once the image is loaded, add it to the stage.

To post to the user’s wall, you need to use this function:
Facebook.api(‘/me/feed’, onMyInfoLoaded, values, ‘POST’);

Values is the message that you want to post.

I’m not affiliated with Facebook or Adobe.