0
votes

I've received notification email from Microsoft about stop supporting Basic Authentication in the Outlook REST API v1.0 which I've been using in my Azure AD registered python flask app.

The API which Microsoft removing, has been superseded by the Microsoft Graph and Outlook REST v2.0 API’s.

What should I have to do in order to move to v2.0?

Here is the part of my config.py file:

O365_BASE_URL = 'https://graph.microsoft.com/v1.0/'
O365_AUTH_URL = 'https://login.microsoftonline.com/common/oauth2/v2.0/authorize'
O365_TOKEN_URL = 'https://login.microsoftonline.com/common/oauth2/v2.0/token'

Do I need to change

O365_BASE_URL = 'https://graph.microsoft.com/v1.0/' 

to

O365_BASE_URL = 'https://graph.microsoft.com/v2.0/'
2

2 Answers

2
votes

I am pretty sure you got a link to respective documentation regarding this retirement and move. Nevertheless here are the links you should follow and read to understand what you need to change:

AS a bottom line I see that you are actually already using the Microsoft Graph. This means you do not have to change anything. If these are all the URLs you use with your REST integration:

O365_BASE_URL = 'https://graph.microsoft.com/v1.0/'
O365_AUTH_URL = 'https://login.microsoftonline.com/common/oauth2/v2.0/authorize'
O365_TOKEN_URL = 'https://login.microsoftonline.com/common/oauth2/v2.0/token'

Than you do not need to change anything. There is no v2.0 of the Microsoft Graph yet. Outlook REST APIs are located at https://outlook.office.com/api. And as per the second link, Microsoft Graph v1.0 matches Outlook REST v2.0.

1
votes

The Outlook REST API v1.0 is not the same as Microsoft Graph v1.0, they are distinct APIs.

The base URI for the Outlook REST API is https://outlook.office.com/api/{version}. So for v1.0 it would be https://outlook.office.com/api/v1.0.

If you're currently using https://graph.microsoft.com/v1.0 then you're already using the current production Microsoft Graph release and you don't need to make any change here.

More importantly, none of this has anything to do with Basic Authentication. That is about how you're obtaining your token, not which API you're using that token with. Given that you're already using the OAuth endpoints, I don't believe you're using Basic Authentication either.