My recent study on address book api of Gmail, Yahoo and Windows Live

Recently I was asked by my job authority to study and research on address book api of Gmail, Yahoo and Windows Live(Hotmail). This study is for friend inviter script of our social networking site hottDhaka.com. It a very good news that all of these email providers has released some sort of web services to access their address book. So now any user using any of the above mentioned email services can access their address book programatically and retrieve, add, edit and synchronize their contacts from a third party application.

I have studied all these api’s and found that, all the providers tried to keep their service as simple as possible. And social networking has a great impact on todays web trend. Otherwise I don’t think that the trio would give these type of functionality. This will greatly help the social networking sites to let their users access their address book directly from their sites and search and invite friends to their sites. While studying these api’s, I found one bottleneck which is not so important and I think developers can overlook this problem. The problem is, any user trying to access their address book from any third party web application, s/he has to authenticate from their respective service providers website. They don’t provide any mechanism for third party sites to authenticate the users off the providers sites. For example, if any Gmail users try to access his email address book from any third party web application, then he will be redirected to Gmail login page, s/he will authenticate him/herself there by providing his username and password, then Gmail send him back to the original site with his address book information. This is for security reason and I think this is ok. At least the developers don’t need to develop the security and login things by themselves as the service providers are take the responsibility to doing this. This also ensure the highest level of security.

But, as usual, Windows Live has another bottleneck I found, at least in my case. For security reason, the use the hash function mhash() for which I have to install the php mhash module. This is very rare module installed in local web hostings. And I still can’t check windows service for mhash() function. So I am looking for a hosting who can give me the mhash support. may be then I can use the api for PHP. Otherwise I have to try at .NET.

And I also tried the Yahoo Addressbook API. At very first sight, I thought Yahoo’s API is the easiest to build and test. But in fact, still I am getting a service unavailable error. And the interesting thing is that, I was trying their web services with a test code downloaded from their web site :D

Though, at first sight, it was seems that, Google’s api is very tough to try. And again interesting matter is that, I first success with Google’s API. I tried and played with their Javascript addressbook api. Its very easy. Google also provides a full working example. I just downloaded it and make some changes need for me. If you like to see, you can see it here.

5 Comments

  1. david.alvaro said,

    August 12, 2008 at 11:40 am

    Hi,
    is easy import contacts from HOTMAIL with php?

  2. kask said,

    September 21, 2008 at 5:32 am

    Quick note on your Windows Live API mhash usage.

    If mhash isn’t compiled, but you are using a high enough version of PHP >5.? you can replace line 1515 of the windowslivelogin library with:
    $key = hash(’sha256′,$key,true);

    It seems to be working for me.

  3. moshfiq said,

    September 21, 2008 at 9:28 am

    @david: its very easy to import contacts from all of hotmail, yahoo and gmail.

    @kask: i tried with sha256. but it doesnt worked for me. may be i missed something. ok i’ll check it again. anyway, thanks a lot for your helpful comment.

  4. rat86 said,

    January 3, 2009 at 9:43 pm

    link:
    http://dbf400c6.fb.joyent.us/dev/2008/8/8/google-addressbook-api/

    don’t work

  5. anu said,

    March 19, 2009 at 1:38 pm

    Hi even I need what exactly your doing (address book api of gmail yahoo and windows live), I am doing that using php, but I can retrieving the contact details form gmail api I can’t add contact from our site to gmail that is the problem. I need to develop this for gmail and yahoo and windows live.

    Can you help me in this, I try to see your Google provides a full working example but I am facing this error “The server at dbf400c6.fb.joyent.us is taking too long to respond.”

    So please kindly send me the example code to my email ID ASAP possible.

    Awaiting for your response,

    Thanks in advance,
    Anu.


Post a Comment