Inside Office 365's APIs

Office 365's APIs are crucial to Microsoft's cloud strategy. Here's a quick primer on how to take advantage of them

Become An Insider

Sign up now and get FREE access to hundreds of Insider articles, guides, reviews, interviews, blogs, and other premium content. Learn more.

Last year Microsoft CEO Satya Nadella said that the Office 365’s APIs were the company’s most strategic -- and most valuable.

Designed to open Microsoft’s cloud productivity platform to developers, Office 365 APIs are collections of tools that simplify building Office’s cloud services into your apps. Microsoft’s cloud services are at the heart of its current strategy, and its APIs are a big part of how it delivers those services to everything from Android phones to Node.js Web applications. 

Using familiar REST APIs, and providing SDKs for common platforms, Microsoft is aiming to use Office 365 and Azure Active Directory as hubs where apps store files and users build collaborative relationships with others.

The underlying technologies Microsoft is using will be familiar to anyone building a modern app that connects to Web services. REST and OData are used to transfer data, while OAuth 2.0 is used for authentication. Drilling down into the APIs, you can start to see how Microsoft is exposing Office 365 to apps. Take email, for example. The structure of a call is based around a root URL that’s made up of a server name, the API version being used, and the user context.

Once you’ve constructed the appropriate root URL, you can start to make calls against the API. If you want to get the inbox messages for the logged-in user, just append “messages” to the root URL. For other folders, you’ll need the folder ID. The response can be large, as it contains details for all the messages in the folder, including content and a full set of headers. Perhaps the most useful element of this response is the message ID, which can be used in further calls to the API – including to obtain the full message, and even to download attachments.

To continue reading this article register now