Home > Net >  Azure chatbot - can I use existing SSO authentication from page?
Azure chatbot - can I use existing SSO authentication from page?

Time:12-13

I'm trying to work out if it is possible to embed my Azure chatbot in a page that is already using Azure AD Single Sign-On.

The specific use-case I'm looking at is embedding the chatbot in a sharepoint page. I have followed chatbot login

In addition to this, once I've logged in, I'm also asked to copy a validation code into the chatbot: validation code

And only when I've entered this code does the bot authenticate me: authenticated chatbot

Essentially I want to know:

  1. Is there any way to configure the bot to auto-detect my authentication through sharepoint?
  2. If not, is there any way to configure authentication without the need for an extra validation code?

Thanks!

CodePudding user response:

Thank you Steven Kanberg and Dana V. Posting your suggestion as an answer to help other community members.

There is no way to get the access token in SPFx. The only solution I have found with SPO/SPFx, is to utilize SPFx to give user context to the bot, and do calls via app-only graph application in the bot. You could add code logic to limit the calls etc to graph/SharePoint using that context.

You can refer to How to Securely Integrate WebChat/Directline in SharePoint Online and How to configure SSO for chatbot deployed on website

  • Related