Open Hack Day Bangalore: Hacking Yahoo! Social

  • 4,341 views
Uploaded on

Introduction to Yahoo! Social APIs

Introduction to Yahoo! Social APIs

More in: Education
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
  • Free Download : http://gg.gg/114bb

    Hey Guyz and girls, Today I am gonna show you perfact tool, Remember This video is old, But the download link with hack is brand new. Its very simple to using this tool and here are some instructions in video. Please REDOWNLOAD. Don't Forget to Comment Subscribe & Rate My Video :)

    Virus Scan :- This file has been scanned with avast! Antivirus. -- Status: FILE IS CLEANN.

    Copyright © 2014. All Rights Reserved
    Are you sure you want to
    Your message goes here
No Downloads

Views

Total Views
4,341
On Slideshare
0
From Embeds
0
Number of Embeds
0

Actions

Shares
Downloads
152
Comments
1
Likes
2

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Hacking Yahoo! Social and Meme Saurabh Sahni Developer, Hacker, Evangelist
  • 2. User Data  Connec/ons  Status  Updates  h3p://pulse.yahoo.com/sahni_saurabh 
  • 3. YAHOO! MESSENGER 
  • 4. Y! Social APIs     SOCIAL      DIRECTORY    YAHOO!   CONTACTS  STATUS  UPDATES  MEME  h3p://developer.yahoo.com/social/ 
  • 5. Leverage Yahoo!’s 600+ million users in your social applications with Yahoo!’s Social APIs.
  • 6. Two ways to hack Social APIs  Open applica/ons are applica/ons  that run on the Yahoo! network or  other open social containers   OAuth applica/ons are standalone  applica/ons that run off the Yahoo!  network. 
  • 7. Easiest way to use Social APIs is via YQL
  • 8. h3p://developer.yahoo.com/yql/console/  h3p://developer.yahoo.com/yql/console/ 
  • 9. Fetching your profile data select * from social.profile where guid=me;
  • 10. Profile Data 
  • 11. Finding your contacts select * from social.contacts where guid=me;
  • 12. Contacts 
  • 13. Fetching any user’s profile data select * from social.profile where guid= ‘7VABDKK365VEHCUDYFO6HUSKQM’;
  • 14. Fetching your updates select * from social.updates where guid=me;
  • 15. Updates 
  • 16. Updates from your contacts select * from social.contacts.updates where guid=me;
  • 17. Updates Firehose Access all Yahoo! Updates in real time via YQL h3p://www.flickr.com/photos/thomashawk/250792779/ 
  • 18. Update Sources: 75+ http://developer.yahoo.com/social/rest_api_guide/updates- update_sources.html
  • 19. Updates Firehose 
  • 20. Finding updates about iPad select * from social.updates.search where query=’iPad';
  • 21. Updates associated with huffingtonpost.com select * from social.updates.search where link='huffingtonpost.com';
  • 22. Tweets in Yahoo! Updates select * from social.updates.search where source = 'twitter';
  • 23. Updates from your application select * from social.updates.search where source = '7BNRkt42';
  • 24. Yahoo! Meme: meme.yahoo.com 
  • 25. My Meme: h3p://meme.yahoo.com/saurabhsahni 
  • 26. Yahoo! Meme Dashabord: meme.yahoo.com 
  • 27. Meme API: http://developer.yahoo.com/meme/
  • 28. More with meme •  INSERT INTO meme.user.posts (type, content, caption) VALUES ("photo", "http://www.yahoo.com/ myphoto.jpg", "this is the photo caption”) •  INSERT INTO meme.user.posts (type, content, caption) VALUES ("video", "http://www.vimeo.com/ 12345", "this video is awesome") •  SELECT * FROM meme.search WHERE query=”hackday” •  SELECT * FROM meme.popular WHERE locale='in'
  • 29. Y! Social SDK   What can you do?  34  h3p://www.flickr.com/photos/phploveme/2847931240/ 
  • 30. Yahoo! Social SDK – Features  •  Examples for OpenSocial, PHP, Python •  Performs OAuth authorizaiton •  REST calls to the Yahoo! Social Web Services –  Fetching Profiles –  Fetching and Inserting Updates –  Fetching Connections –  Executing YQL
  • 31. SDK Languages  hHp://developer.yahoo.com/social/sdk/ 
  • 32. Scalable Hosting h3p://signup.joyent.com/yahoo_signup  
  • 33. Example Apps
  • 34. Flixter on Yahoo! USER DATA  AUTHENTICATION  CONTACTS  DATA       UPDATES    LOCATION 
  • 35. Updatesville
  • 36. Updatesville
  • 37. Social Search Social Search
  • 38. Social Search
  • 39. Slidememe
  • 40. Slidememe Slidememe
  • 41. Hack: Updates in your language h3p://www.flickr.com/photos/dimitridf/2841804136/ 
  • 42. DEMO
  • 43. h3ps://developer.apps.yahoo.com/projects/  
  • 44. h3ps://developer.apps.yahoo.com/projects/ 
  • 45. Gadget XML: h3p://github.com/saurabhsahni/Hacks  
  • 46. PHP Code: h3p://github.com/saurabhsahni/Hacks 
  • 47. PHP Example: OAuth Dance  $session = YahooSession::requireSession($key, $secret, $app_id) $user = $session->getSessionedUser(); var_dump($user);
  • 48. Social Data with YQL ‐ Recap   select * from social.profile where guid=me select * from social.connections where owner_guid=me select message from social.profile.status where guid=me select * from social.updates where guid=me
  • 49. PHP Example: ExecuTng YQL  $session = YahooSession::requireSession($key, $secret, $app_id) $results = $session->query(‘select * from social.updates where guid=me’); var_dump($results);
  • 50. PHP Example: InserTng Updates  $session = YahooSession::requireSession ($key, $secret, $app_id) $user = $session->getSessionedUser(); $update = $user->insertUpdate($suid, $title, $link, $description); var_dump($update);
  • 51. GeUng Started ‐ DocumentaTon •  Yahoo! Social APIs - http://developer.yahoo.com/social/ •  Meme APIs: http://developer.yahoo.com/meme/ •  Yahoo! Query Language - http://developer.yahoo.com/yql/ •  Yahoo! Social SDKs- http://developer.yahoo.com/social/sdk/ •  Examples - http://github.com/saurabhsahni/Hacks
  • 52. THANK YOU!  Saurabh Sahni  h3p://www.saurabhsahni.com   h3p://twi3er.com/saurabhsahni  h3p://pulse.yahoo.com/sahni_saurabh   h3p://slideshare.net/saurabhsahni 
  • 53. Appendix
  • 54. What is OpenSocial?  •  OpenSocial API  •  For developing applicaTons on social  networks  •  Accessing social data (profiles, connecTons)  •  Fetching and inserTng acTviTes  •  Implemented by many containers  •  Develop once, distribute broadly 
  • 55. Python Example: OAuth Dance  oauthapp = yahoo.application.OAuthApplication (key, secret, app_id, callback) # fetch unauthorized request token request_token = oauthapp.get_request_token(callback) # authorize request token authorization_url = oauthapp.get_authorization_url(request_token) # refresh authorized request token with access token access_token = oauthapp.get_access_token(request_token) oauthapp.token = access_token
  • 56. Python Example: Fetching Profile Data oauthapp = yahoo.application.OAuthApplication(key, secret, app_id, callback) profile = oauthapp.getProfile() print profile
  • 57. Python Example: ExecuTng YQL  oauthapp = yahoo.application.OAuthApplication(key, secret, app_id, callback) results = oauthapp.yql('select * from social.profile where guid=me') print results