how to register your application to authorize o365 graph api

13
Rakesh Sharma BRISTLECONE INDIA HOW TO REGISTER YOUR APPLICATION TO AUTHORIZE O365 GRAPH API

Upload: rakesh-sharma

Post on 13-Apr-2017

239 views

Category:

Technology


0 download

TRANSCRIPT

Rakesh Sharma

BRISTLECONE INDIA

HOW TO REGISTER YOUR APPLICATION TO AUTHORIZE

O365 GRAPH API

How To Register Your Application To Authorize O365 GRAPH API

1 | P a g e

How To Register Your Application To Authorize O365 GRAPH API

2 | P a g e

Contents 1 How to add an application in Azure ..................................................................................................... 3

2 How to configure an application .......................................................................................................... 7

2.1 How to add other O365 Applications and configure permissions .............................................. 10

How To Register Your Application To Authorize O365 GRAPH API

3 | P a g e

1 How to add an application in Azure Login in Azure portal using your admin privileges. Find ACTIVE DIRECTORY in left pane where a list of

services are visible like NETWORKS, TRAFFIC MANAGER, and MANAGEMENT SERVICES and so on.

(Screen 1.1)

Screen 1.1

When you click on ACTIVE DIRECTORY, right screen refresh with title as Active Directory. It shows

available active directory in Azure. In our example, it is by name of Freelance. (Screen 1.2)

Screen 1.2

How To Register Your Application To Authorize O365 GRAPH API

4 | P a g e

When you click on Active Directory name, it gives you active directory page where you can manage

users, their groups, applications, and many more. (Screen 1.3)

Screen 1.3

To add your own application in Azure, you need to go on Applications tab of the screen. When you

click on Applications tab, you find the similar screen as Screen 1.4. Applications which are published

by Microsoft Corporation are default applications added to your Azure instance. Others are

authorized by you and added in the list.

Screen 1.4

To add a new application, in the Azure, click on Add button, bottom down pane on the screen. It will

pop up a small wizard to add a new application in Azure. (Screen 1.5). Choose first option as:

How To Register Your Application To Authorize O365 GRAPH API

5 | P a g e

“Add an application my organization is developing”

Screen 1.5

Next page, asks for application name and type of application. For example, application name is

TestO365Connector and application type is Web Application. We can have NATIVE CLIENT where we

don’t need to use any web portal.

Screen 1.6

Give Application properties like Web URL where user can do sign on and a unique id of the

application on Web Server. Finish it. (Screen 1.7 and 1.8)

How To Register Your Application To Authorize O365 GRAPH API

6 | P a g e

Screen 1.7

Screen 1.8

Application is successfully registered and added in the list. Now you need to configure your

application to get Client Key and Secret Key of your application. These keys are required to generate

access token for your application.

How To Register Your Application To Authorize O365 GRAPH API

7 | P a g e

2 How to configure an application You can see application attributes, by clicking on Configure tab. Some information would be same as

you provided at the time of application registration and some information would be new for you

which you can configure on this page.

Screen 2.1

After Logo and Tenant information, you can find client id of your application. Copy and store it

somewhere.

Screen 2.2

Keys section shows to generate some keys. These keys are secret keys and visible only after saving

the form. For that, you select, licensing duration, from the dropdown and click on save button in the

How To Register Your Application To Authorize O365 GRAPH API

8 | P a g e

bottom of the screen.

Screen 2.3

Now, you go up and see, Key is generated and visible. (Screen 2.4) Copy it and store it somewhere.

Once you leave this page, this key will not be visible again. It will be replaced by encoded characters.

(Screen 2.5)

Screen 2.4

Screen 2.5

Other attributes like SSO, are also on the same page. If your application need to support SSO, APP ID

URL and Reply URL must be given. Reply URL must be valid URL because Azure will redirect to it

when Authorization key will be asked through GRAPH API. For token generation, this value is not

considered. (Screen 2.6)

How To Register Your Application To Authorize O365 GRAPH API

9 | P a g e

Screen 2.6

How To Register Your Application To Authorize O365 GRAPH API

10 | P a g e

2.1 How to add other O365 Applications and configure permissions By default Azure Active Directory is always added for your application. For web applications, we have

two types of permissions

1. Application permissions

2. Delegated permissions

In case of native application, you will be asked Delegated permissions only. For example, for Azure

active directory, you can add following permissions to your application.

Screen 2.1.1

Screen 2.1.2

To add another Microsoft application, click on Add application button just near to “Permissions to

other Applications”. Choose any application from the pop up list. For example, we have chosen,

Office 365 Exchange Online. (Screen 2.1.3)

When you add the application, it is listed in right pane of “Selected” applications. Now you click on

Ok button in right bottom. (Screen 2.1.4) Application is added in the list. (Screen 2.1.5)

How To Register Your Application To Authorize O365 GRAPH API

11 | P a g e

Screen 2.1.3

Screen 2.1.4

Screen 2.1.5

You can find different permissions for this application and can choose out of them, as per your need.

(Screen 2.1.6 and Screen 2.1.7)

How To Register Your Application To Authorize O365 GRAPH API

12 | P a g e

Screen 2.1.6

Screen 2.1.7

That is it and now you know how to add and configure an application in Azure AD.