- Supports only SharePoint Online
npm install spaddin-helper --save
In a Node http request handler
const handler = (req, res) => { let ctx = SharePointContext.getFromRequest(req); ctx.createAppOnlyClientForSPHost().then(client => { client.get('/_api/web/currentuser').then(user => { console.log(
username = ${user.Title}
); }); }); };