Wrapper of Microsoft Graph
A Node-RED node to perform an OAuth2 Authentication with Microsoft Graph.
npm install node-red-contrib-viseo-ms-graph
Register the Application
- Sign into the App Registration Portal using either your personal or work or school account.
- Choose Add an app.
- Enter a name for the app, and choose Create application. The registration page displays, listing the properties of your app.
- Copy the Application Id. This is the unique identifier for your app.
- Under Application Secrets, choose Generate New Password. Copy the password from the New password generated dialog. You'll use the application ID and password (secret) to configure the sample app in the next section.
- Under Platforms, choose Add Platform.
- Choose Web.
- Enter https://server.url:1880/callback-auth as the Redirect URI.
- Choose Save.
Build the Node-RED Flow
This sample demonstrate an authentication throught a ChatBot.
The first row build an URL to
https://login.microsoftonline.com/common with credentials then send a ChatBot Sign-In Card
The second row
- handle HTTP GET Request to
/callback-authand answer a "Thank You" message.
- the callback
codeis resolved into a
- the callback
stateis resolved to fetch the ChatBot user, save the credential and send back a message.
The third row try to retrieve the microsoft profile with an HTTP request to
For further help, or general discussion, please use the github issue tracker and in order to be labeled with
question tag please specify :
- Your message is a question / discussion
- The module or node name
Before raising a pull-request, please read our contributing guide.
This project adheres to the Contributor Covenant 1.4. By participating, you are expected to uphold this code. Please report unacceptable behavior to any of the project's core team.
- Jean-Philippe Encausse @jpencausse