# Microsoft

Microsoft provides a standardized way to access their APIs through Microsoft Azure. This can be done using **OAuth**. Once configured, you can use your credentials to authenticate the following nodes:

## Microsoft compatible nodes

| Node                     | OAuth                                 |
| ------------------------ | ------------------------------------- |
| Microsoft Dynamics CRM   | <mark style="color:green;">Yes</mark> |
| Microsoft Excel          | <mark style="color:green;">Yes</mark> |
| Microsoft Graph Security | <mark style="color:green;">Yes</mark> |
| Microsoft OneDrive       | <mark style="color:green;">Yes</mark> |
| Microsoft Outlook        | <mark style="color:green;">Yes</mark> |
| Microsoft Teams          | <mark style="color:green;">Yes</mark> |
| Microsoft To Do          | <mark style="color:green;">Yes</mark> |

## Account integration using OAuth

To begin, you will need:

* An [Microsoft Azure](https://azure.microsoft.com/) account.

**STEP 1:** Access the [Microsoft Application Registration Portal](https://aka.ms/appregistrations).

**STEP 2:** Click on the **\[Register an application]** button.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FHW7YhJJdzjFwNjZSLJPd%2FScreenshot_20230117_121603.png?alt=media&#x26;token=88d6136e-f1cb-4380-9a63-6441ed95e3b2" alt=""><figcaption></figcaption></figure>

**STEP 3:** Enter a name for your app in the **Name** field.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FtJdds5BEJNzwx8rXIKQF%2FScreenshot_20230117_121651.png?alt=media&#x26;token=f9bd36f8-4d74-4e8f-ab9b-1bfba5b0d793" alt=""><figcaption></figcaption></figure>

**STEP 4:** Select **Accounts in any organizational directory (Any Azure AD directory - Multitenant) and personal Microsoft accounts (eg. Skype, Xbox)** under the **Supported account types** section.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FXGsfWqTvmzujyRkJPguH%2FScreenshot_20230117_020352.png?alt=media&#x26;token=bbaabc34-652b-4e9e-a7ff-9a16f9c8ff47" alt=""><figcaption></figcaption></figure>

**STEP 5:** In iMBrace, copy the **OAuth Callback URL** provided in the Microsoft node credentials.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2F6A23eNcq4y8G8BSQRhzR%2FScreenshot_20230117_020834.png?alt=media&#x26;token=6a02b65c-e84c-417f-8dad-a7290d34fa02" alt=""><figcaption></figcaption></figure>

**STEP 6:** Paste it in the **Redirect URI (optional)** field on the **Register an application** page.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FMnMOkK05nIsMv0Pnj2KC%2FScreenshot_20230117_021123.png?alt=media&#x26;token=ca7827ca-716f-48fa-b57a-fad84b7d8341" alt=""><figcaption></figcaption></figure>

**STEP 7:** Click on the **\[Register]** button.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FVJHduziwRlJrpWlfQdfj%2FScreenshot_20230117_021226.png?alt=media&#x26;token=d01871ec-007b-47ff-9b84-a1620434ee73" alt=""><figcaption></figcaption></figure>

**STEP 8:** Copy the **Application (client) ID**.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FB1ynO36pt2ljKSrgmG8N%2FScreenshot_20230117_021316.png?alt=media&#x26;token=f902f1e1-4557-492f-91df-3fe15bd6e5c4" alt=""><figcaption></figcaption></figure>

**STEP 9:** In iMBrace, enter the name for your credentials in the **Credentials Name** field in the Microsoft node credentials (In this case, Microsoft Outlook).

**STEP 10:** In iMBrac&#x65;**,** paste the Application ID in the **Client ID** field in the Microsoft node credentials.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2F00UHYY88CG5Zwv7LBOk2%2FScreenshot_20230117_021624.png?alt=media&#x26;token=4ba52bc0-5796-411d-b24e-c8e668eee57e" alt=""><figcaption></figcaption></figure>

**STEP 11:** On your Microsoft application page, click on **\[Certificates & secrets]** in the left sidebar.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FCI1maWOGsQSs68boZxYq%2FScreenshot_20230117_021741.png?alt=media&#x26;token=14784704-287d-40da-a16b-c8d3f1e2674f" alt=""><figcaption></figcaption></figure>

**STEP 12:** Click on the **\[+ New client secret]** button under the **Client secrets** section.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FPJBdrnWAPMm4IgiykEgu%2FScreenshot_20230117_023500.png?alt=media&#x26;token=41b32545-3131-41ee-90cb-c079d93720ee" alt=""><figcaption></figcaption></figure>

**STEP 13:** Enter a description in the **Description** field.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FtTn6jbR60YXTh7G1Jh0W%2FScreenshot_20230117_021904.png?alt=media&#x26;token=e56163ca-9e38-4c9d-9011-935ede7624f6" alt=""><figcaption></figcaption></figure>

**STEP 14:** Click on the **\[Add]** button.

**STEP 15:** Copy the displayed secret under the **Value** column.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FRNhc38Kj8ZsB3E4Z2O1C%2FScreenshot_20230202_104019.png?alt=media&#x26;token=97b58329-665c-40fd-a3c7-3fdf3db9aa09" alt=""><figcaption></figcaption></figure>

**STEP 16:** In iMBrace, paste the secret in the **Client Secret** field in the Microsoft node credentials.

<figure><img src="https://3400071099-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FypCKq44Psaly6khgrY7x%2Fuploads%2FznEcXKBn1Jx73GdjqCJ7%2FScreenshot_20230202_104145.png?alt=media&#x26;token=47755b69-31a8-4485-8377-d6e77bd9b655" alt=""><figcaption></figcaption></figure>

**STEP 17:** Click on the **\[Connect]** button in the OAuth section to connect a Microsoft account to iMBrace.

**STEP 18:** Login to your Microsoft account and allow the app to access your info.

**STEP 19:** In iMBrac&#x65;**,** click on the **\[Save]** button in the Microsoft node credentials to save your credentials.

**DONE:** The credential can then be used for Microsoft nodes.
