duminică, 9 noiembrie 2008

Yahoo uuuuuuuuu! 2 smart for me (part 1)

This morning I started to look into Yahoo!'s Social APIs and O did i regret it. (If you are not familiar with Yahoo Api you cand get a nice idea here )


It all sounds fun and simple so I started out with Yahoo! Social Directory, a component of the YSP (Social Platform). "READY TO GET STARTED?", read the documentation and make your own application.


3, 2, 1, GO!

You read that there's a thing called PHP SDK, practically a PHP library to interact with Y-API and retrieve informations etc. So I get started with the tutorial.


Getting Started with the PHP SDK

The tutorial has 3 steps that are estimated at 30 minutes (15 more than you need).

The main idea is that you make a PHP script that first connects to Yahoo Database, access user informations ( they come back as objects ), parse/display/etc. and then you publish it on your domain or a Yahoo page.

Step 1 :

You learn to make a simple PHP script (well documented) that receives profile info, status updates, contacts, connections and status message of an Yahoo user, using functions provided through Y API. At the end there is a textbox with the full code of the file "mysocial.php" (very useful)


Between steps :

To access Social Directory data with your PHP script you need an API Key and a Shared Secret ( a second key ).
There are defined 2 types of applications OAuth and Open. They will run the same php script (step 1) but the difference between them is that Open applications are available on Yahoo! sites, and OAuth are available on your site.


to be continued...

Niciun comentariu: