graph-interface-desktop-provider
Provides an oAuth2 Authentication for the graph-interface module.
Installation
Run
npm install graph-interface-desktop-provider --save
or, if you use Yarn
yarn add graph-interface-desktop-provider
Usage
First import the module and the graph-interface module.
const createGraphInterface = require('graph-interface');
const createDesktopMiddleware = require('graph-interface-desktop-provider');
Then use in the authorizationProvider
option when creating your graph interface:
const graph = await createGraphInterface(credentials, {
authenticationProvider: createDesktopMiddleware(options)
});
Options
{
refreshTokenPath: '.'
}