I was attached to a pretty interesting project a few months ago. Microsoft wanted an App for Word code sample that would show how to retrieve citations from Zotero (a research assistance service that helps manage sources and citations) and insert chosen citations into a word document. The kicker was that Zotero uses OAuth 1.0 for authentication. I was vaguely familiar with OAuth at the time, and given its prominence in Apps for Sharepoint really wanted to get more acquainted with it.

This app gave me the chance to learn OAuth in depth (well, OAuth 1.0 anyway, which made learning OAuth 2 for later project all the easier). It also gave me a forceful thrust into the particular setup Apps for Office needs in order to allow OAuth.  Because users’ calls cross security domains, OAuth provides a convenient way of passing tokens securely without compromising passwords.

In addition to the published code sample and specifically because it is important to know OAuth when developing these types of solutions, Microsoft requested I write a blog post that shares my experiences getting OAuth to work. I’m very proud to say that, as my first professional blog post, it was a resounding success. Stephan Oliver published it on MSDN, and can be found here.

The code sample itself, which not only includes OAuth in Apps for Office, but also how to insert data into Word from an App for Word, can be found here or by following the links in the MSDN blog post. It was a very fun project to do and a great learning experience for me.  I know it will be very useful for others that want to learn how to use OAuth with Apps for Office. Stay tuned for more, as I’ve recently finished a different app that uses OAuth 2.0 with an App for Office!