Questions tagged [outlook-restapi]

The Outlook REST APIs include the Mail, Calendar, and Contacts APIs in Office 365.

Welcome to the outlook-restapi tag! Please use this tag to find answers, ask questions, and answer questions about using the Outlook REST APIs.

The Outlook REST APIs are comprised of three distinct APIs that provide access to users' data in Office 365:

  • Mail API: Used to manipulate mail and mail folders.
  • Calendar API: Used to manipulate events and calendars.
  • Contacts API: Used to manipulate contacts and contact folders.

Getting Started

Want to explore and play with the APIs? Check out the Office 365 OAuth Sandbox. You can quickly issue queries against your own data, or against a sandboxed environment.

The Outlook Dev Center has getting started guides in a number of different languages. Start from scratch and end with a working app that retrieves messages from the inbox.

Looking for code samples? Check out the Office Dev Center's Code Samples page. PHP, Node.js, Rails, and more!

Looking for more information, or just want to keep abreast of updates to the APIs? Follow the Outlook REST APIs team's blog.

966 questions
5
votes
0 answers

HTTP 503 with ResourceUnhealthy

Sometimes Microsoft outlook or graph API return HTTP 503 ResourceUnhealthy error response for specific mailboxes. The description mentions: ResourceUnhealthy SystemMemoryProtectionUtilizationMonitor is unhealthy What does it means and what may…
5
votes
1 answer

Using Outlook REST API Beta From an Outlook add-in

I have created an outlook add-in with ReactJS and followed this guide to get a token to be able to use the Outlook v2.0 REST APIs: https://learn.microsoft.com/en-us/office/dev/add-ins/outlook/use-rest-api Now I would like to start using the Outlook…
5
votes
0 answers

Find out through Microsoft Graph if a room is bookable by current user

Sometimes there are certain rooms that are only bookable by a subset of the users at a company. In these cases, is there any way through the Microsoft Graph API to determine if the current user can book a room? We would like to do this without…
5
votes
0 answers

Call Microsoft Graph API directly from Outlook add-in

I have a React-based SPA Outlook add-in, and I am trying to make calls directly to the Microsoft Graph API. Is there a way to utilize Office.context.mailbox.getCallbackTokenAsync() or Office.context.auth.getAccessTokenAsync() to get an AccessToken…
Dave
  • 2,409
  • 3
  • 22
  • 28
5
votes
0 answers

How to send nested attachments?

Stuck here writing JS code to send out an email via REST within a custom Outlook add-in. Scenario is following report \ \---- another message (item attachment) \ \------- attachment (file attachment) In words, I am sending a…
5
votes
0 answers

How to access a shared mailbox via Office365 Rest API?

We can access the shared mailbox if it is shared with a user by using user's OAuth. Whereas here I want to access a shared mailbox which doesn't have a user via Office 365 Rest API. Is it possible via Rest API? or Can we achieve the same via EWS or…
5
votes
1 answer

Filtering on iCalUId returns empty array if event is part of a series

My question is nearly identical to this question. I would have just commented over there but am unable to do so due to being a new user. My request to https://graph.microsoft.com/v1.0/me/events?$filter=iCalUId eq '' returns the event object…
kurts
  • 79
  • 6
5
votes
2 answers

Graph authentication through Client Credentials flow - Will my app have access to just my user account or to the whole organization?

I have a daemon script that needs to access my Office 365 inbox to read messages. Currently I am using basic authentication with V1.0 of the Outlook Rest API, which works well but since it is being discontinued I am looking to move to the Graph API…
BigGerman
  • 525
  • 3
  • 11
5
votes
1 answer

Hybrid environments, 404 with on-premise mailboxes, 200 for Exchange online

I've written an application which is able to talk to Exchange Online accounts, I'm currently trying to test to see the steps required to get it to work with on-premise accounts running in Hybrid. I have: Windows Server 2012 R2 Exchange 2016 CU8…
Omar Qureshi
  • 8,963
  • 3
  • 33
  • 35
5
votes
2 answers

Create calendar event using Microsoft Graph Client

I'm trying to figure out how to create a calendar event using the Microsoft Graph JavaScript Client. I've managed to retrieve the necessary accessToken and can interact with the API (i.e. retrieve events, calendars, top 10 e-mails), but I'm not sure…
Julio Costa
  • 343
  • 2
  • 4
  • 13
5
votes
1 answer

Send new message that includes a different message from user's inbox as attachment

I am working on a multi-tenant daemon application. The application needs to send an email on behalf of the user. The email sent by the application would have to include another email from the user's inbox as attachment. Can this be achieved by…
Dhana
  • 73
  • 3
5
votes
1 answer

Authentication in Outlook 365 api

My use case is: make a script that will run every hour to extract information about a user's calendar. My script runs in Python and I get a token but I am unable to get the user's events. I have registered my app in the Microsoft Application…
Fabrice Dugas
  • 509
  • 1
  • 5
  • 15
5
votes
1 answer

The enduring saga of when to use EWS vs the Rest API in an Outlook Add-in

This question is based on a previous question I asked but with a bit more detail and experience since. First some background, I have an Outlook Addin that should forward a users message and then move the message to a specific folder. This needs to…
5
votes
1 answer

Stay logged in when using msal.js

I'm building a small JS app for my Microsoft ToDo tasks and use the msal.js library to accommodate the authentication process. This works perfectly fine, I get a popup, I authenticate my profile, the popup closes and my tasks appear on my screen.…
CaptainCarl
  • 3,411
  • 6
  • 38
  • 71
5
votes
1 answer

Outlook Add-in Office-Js Authentication

I am building a React based Outlook Add-in. I set up my project using the YeomanGenerator. I am trying to set up authentication using Office-Js-Helpers. I am able to create the authenticator, register the microsoftAuth Endpoint. My add in opens…
Lani
  • 61
  • 4
1 2
3
64 65