eric dombroski

Exchange To Google Contacts Sync

As part of my relentless pursuit to simplify my life by having all of my important data available anywhere, any time, via any application, running on any system, from any device, as well as a exercise to learn a “real” (non-scripting) computer language, I set about to create an app to sync the contacts between my Exchange 2003 mailbox and my Google Contacts repository.

Design Goals

  • Developed in C#, targeting the .NET 2.0 framework.
  • Initially, just a simple console application, but eventually a full Windows.Forms package.
  • Utilize Google’s Contacts API to access/update Google Contacts, and WebDAV to access/update Exchange contacts.
  • Sync any and all attributes possible.
  • Work around GMail’s tendency to create a new contact for any new email address, regardless of one might already exist for the same person (e.g. some sort of duplicates resolution)
  • Full two-way attributes sync
  • At least one-way (Exchange–>Google) contact creation and deletion
  • Lofty: contacts backup/restore

Challenges/Limitations

  • E-Mail, Postal Address, and Phone numbers appear to be easy, but WebDAV doesn’t appear to expose the “IM Address” feature of the Exchange contact.  This may be resolveable, particularly through Exchange 2007 Web Services, but we’re not there yet.
  • The Google Contacts API doesn’t appear to have a mechanism to update the contact picture yet, but apparently it is being considered.
  • XML responses from Exchange 2003s WebDAV have some data weirdness issues that have to be worked around.

Current Progress

I currently have a proof of concept that deletes all Google Contacts and creates new ones from what exists in my Exchange mailbox.  The immediate goal is to get true synchronization working, and then make it generic enough as to be fit for public release.  At that point, I will consider working on two-way attributes syncing.