Switch to the store?

Facebook Graph API Development with Flash

More Information
  • Make your AS3 projects more social and personalise them for your users by adding Facebook integration
  • Grab information directly from Facebook into your applications by using Facebook's Graph API
  • Securely authenticate your users with OAuth 2.0 to log them into Facebook
  • Access information about your users and their friends directly from Facebook – no need to make them type it all in again
  • Upload photographs, add wall posts, and create events through AS3
  • Search on Facebook's databases with the powerful Facebook Query Language
  • Build an AS3 Facebook SDK that you can drop into any AS3 project to add Facebook integration
  • Easily access both public and private Facebook data from the surface of a graph
  • Learn with exercises and fun examples illustrated with diagrams and screenshots



The Facebook platform provides you with an ideal solution for building rich, social experiences on the web to develop an effective user experience application. Combined with Flash which effectively enables social interactions, you can create a fully functional application on Facebook. If you've been waiting to get started with your own applications and games on Facebook, with this book you don't have to wait any longer.

This book takes you through everything you need to know to integrate your AS3 apps and games with Facebook accompanied by illustrative screenshots and short quizzes.It presents you with in depth coverage of the key underlying concepts such as creating a basic application that runs inside Facebook and exploring the Graph API which greatly simplifies how developers can retrieve data. This book also covers topics on security, permissions and authentication features on Facebook.

This beginner's guide starts off by teaching you about retrieving simple public data and then rapidly working your way up to authenticating users, building powerful searches across the entire database, and uploading photos and other content.

Throughout the book, you'll learn by building two fundamental components: an RIA Facebook interface and an AS3 SDK that you can drop into any project to add Facebook integration. This easy-to-understand guide has everything written as AS3-only projects with publicly available components, so you can follow along whether you use Flash Pro, Flex, or MXMLC – as long as you know AS3!

This hands-on tutorial will present you with a whole new perspective of the three core aspects of Facebook – searching, retrieving, and updating the data .This practical book focuses on how to set up an application on Facebook and how to deal with different contexts like AIR.

By the end of this book, you will be confident enough to set up your own application and create social interactions for users to share on Facebook.

  • Build your own interactive applications and games that integrate with Facebook
  • Add social features to your AS3 projects without having to build a new social network from scratch
  • Learn how to retrieve information from Facebook's database
  • A hands-on guide with step-by-step instructions and clear explanation that encourages experimentation and play
Page Count 324
Course Length 9 hours 43 minutes
ISBN 9781849690744
Date Of Publication 14 Dec 2010
Accessing the Graph API through a Browser
Time for action – loading a Page
Accessing the Graph API through AS3
Time for action – retrieving a Page's information in AS3
Time for action – deserializing a JSON object
Time for action – visualizing the info
Understanding connections
Time for action – finding connections in a browser
Time for action – rendering Lists of Posts
Time for action – displaying a Graph Object's connections
Time for action – creating an HTTP Requestor
Understanding Connections of Connections
Time for action – loading photos from an album
Putting it all together
Time for action – traversing the Graph
What can you see?
Time for action – snooping through other people's accounts
What's that got to do with the Graph API?
Time for action – registering an application with Facebook
Time for action – requesting an access token with the browser
Authenticating with AS3
Time for action – Using an access token in our Graph visualizer
Time for action – authenticating through the application
Time for action – authenticating via JavaScript
Extended permissions
Time for action – obtaining extended permissions
Time for action – requesting extended permissions
Using the Adobe ActionScript 3 SDK for Facebook platform
Time for action –implementing the SDK
Getting more results with paging
Time for action – displaying the number of objects in a list
Time for action – requesting more Objects
Time for action – requesting more Objects at once
Time for action – obtaining data in pages
Time for action – adding limit and offset to GraphRequest instances
Time for action – requesting data based on date
Time for action – adding since and until to GraphRequest instances
Time for action – filtering by date using the UI
Time for action – using the ids parameter in a Graph URL
Using the website's Search box
Time for action – examining quick search results
Time for action – Using the Full Search results
Searching with a Graph URL
Time for action – searching without authorization
Time for action – searching while authorized
Time for action – implementing a Search window in the Visualizer
Time for action – searching via the SDK
Time for action – searching your news feed
Time for action – searching a friend@#U+0027:s Wall Posts
Time for action – searching feeds through the Visualizer
Hello, Facebook!
Time for action – posting to the user's feed
Time for action – using the POST method
Time for action – listening for errors
Time for action – granting the required permission
Time for action – posting via the SDK
Going further with Wall Posts
Time for action – publishing rich posts
Posting to another Wall
Time for action – posting to another Wall using the Visualizer
Time for action – literally
Time for action – setting a Post's privacy settings
Deleting Graph Objects
Time for action – deleting a Post
Time for action – deleting Posts using the Visualizer
Publishing other kinds of Graph Object
What about...?
What is FQL?
Understanding the FQL interface
Getting information
Time for action – retrieving info from the Page table
What about connections?
Time for action – getting a user's friends' names with AS3
Time for action – an easier way
Time for action – getting it down to one API call
The Graph as a layer
Advanced FQL
Putting it online
Time for action – setting up an IFrame application
Time for action – adding an application to a Page tab
Time for action – authorizing through AIR with HTTP
Time for action – authorizing through AIR with the SDK
Time for action – authorizing on Android
Getting your application out there
Watch out for these policies!
What next?
Keeping up with the Zuckerbergs


Michael James Williams

Michael James Williams is a freelance Flash developer and technical concept writer. He is the technical editor for Activetuts+, and writes AS3 game development tutorials on his blog. You can find him on Twitter, too: @MichaelJW.