How to retrieve the GUID for Yahoo's Contacts API
I'm attemping to use the Yahoo Contacts API to add an "invite your friends" feature on a site I'm building.
I've开发者_Python百科 found the correct web service to call (http://social.yahooapis.com/v1/user/{guid}/contacts
) but it is asking for the user's GUID, not their username/password.
I've searched, and am unable to find a "lookup" feature through the Yahoo API which lets me get the user's guid from their username/password.
Does anyone have any experience with the Contacts API.
I've reaad over the documentation, and looked at YQL as well, but I still haven't found how to get the user's guid.
Thanks guys.
This is from their developer documentation:
To get the GUID of the user who is running the application, call the GET operation on the following URI. This user must be signed in to Yahoo!
URI: http://social.yahooapis.com/v1/me/guid
http://developer.yahoo.com/social/rest_api_guide/introspective-guid-resource.html
Note that you can't login the user silently -- you need to display the Yahoo login page with a pop-up window and get an OAuth token (more info about this found in the dev docs).
You can use simply:
http://social.yahooapis.com/v1/user/me/contacts
First you need to signup your application to YDN. than you will get a consumer key and consumer secret to implement oAuth.When you get your application authorized by user.then yahoo passes you a access token and GUID by which you can call yahoo's social api.
check this out
精彩评论