Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.



Published on

  • Be the first to comment


  1. 1. FacebookGonna say some techie stuff about APIs and that
  2. 2. Anatomy 1. Widgets 2. Pages 3. FB Connect 4. Applications x. The Facebook vision
  3. 3. 1. Widgets ● Very easy, very powerful, copy and paste ● The “like” button, Facepile, comments box, etc ● “Like” button + Open Graph = a Facebook Page! ● Advantages: viralness, Facebook brand ● Analytics ● 'Like' or 'recommend'
  4. 4. 2. Pages ● For when you want to be on Facebook but not as a friendable person ● Ready made hub, could even replace a website. Easy viralness and kudos of FB brand. ● Default tabs: wall, info, photos, etc ● Can change 'home' tab ● Custom tabs: Big deal. ● FBML being deprecated for iFrames. ● Loads of applications can run in tabs ● Most notable are apps that integrate with the wall, eg; cross-posting Twitter feeds, blog posts, Flickr photos etc ● NB. That Joe Public can make these Page-integrating apps ● You can get the 5000 most recent fan IDs of a social object
  5. 5. 3. Facebook Connect ● Bonafide application territory; but, basic user-management is enough of a feature in itself ● 'Basic information' = Full name, profile pic, gender, friends, 'everyone' data ● Permissions. Don't ask for too many. ● publish_stream, offline_access, email, read_stream (Activity Streams standard), read_inbox, xmpp_login (XMPP is another open standard) ● photos, videos, etc and you can ask to access these for the app user's friends! ● Can ask for permissions when user first connects to app or can 'extend' at any point afterward too.
  6. 6. ● Internal Vs. External ● Extra JS SDK methods for iFrames; dynamic resizing of iFrame and messing with the URL ● Mafia Wars, Farmville. Don't know anything about them because I blocked them from my stream :( ● Graph API ● Replaces old API. The new 'open' vision, more structured, everything is a social object. ● True RESTful API interface – Means lots of SDKs; PHP, Ruby, Python –[foo] – – JSON 4. Applications
  7. 7. ● ● Receive App ID and secret ● Lots of settings ● Icon, logo & FB Connect logo. Named developers. Email contact. ● All apps get their own bonafide FB Page ● Important links; ● ● ● ● Bug tracker ● Forums ● Documentation STEP 1. Registering
  8. 8. Surprisingly easy :) <div id="fb-root"></div> <!--<script src=""></script>--> <script src=""></script> <script> FB.init({ appId : 'YOUR APP ID', // [REQUIRED] status : true, // check login status [OPTIONAL] cookie : true, // allows server to access the session [OPTIONAL] xfbml : true // parse XFBML [OPTIONAL] }); </script> STEP 2. Hello World
  9. 9. ● Either XFBML or JS's FB.login() ● OAuth 2.0 (NB. Facebook is an OpenID relying party) ● Cookie is registered which can be used by server-side SDKs. ● XFBML: X stands for XHTML, JS SDK parses it. ● Canvas legacy. Relatively useless. FBML only used by Page Tabs now and not for much longer either. – Simple <fb:name> – Complex <fb:multi-friend-selector>, <fb:comments> cannot be provided in any other way. STEP 3. Add a login button
  10. 10. ● JS SDK has 1 other class of methods unique to it; FB.ui ● Dialogs, exteneded permissions, posting to user's wall, sharing, etc. ● The API: ● JS has it (FB.api) just like all the others (PHP, Ruby, etc). ● You can read and write to and from user's (and Pages) accounts. ● Subscribe to individual real-time updates! ● Progromatically access analytics. ● You are rate limited, but it's a secret :s ● You are now allowed to cache data indefinitely (may be 1 or 2 exceptions) ● FQL: ● Very powerful, worthy of a page in itself. Sub queries, multiple queries per API call. ● Read-only. ● AFAIK everything can be accessed through FQL! STEP 4. Do stuff