[英]SharePoint Online Get Authentication token without redirecting to URL
I have a ChatBot using Microsoft Bot Framework which is hosted on azure which gets data from a SharePoint list and displays the same. 我有一个使用Microsoft Bot Framework的ChatBot,它托管在azure上,后者从SharePoint列表中获取数据并显示相同内容。 This chatbot is used in SharePoint page.
此聊天机器人用于SharePoint页面。
When used first types in message, bot responds with address of URL clicking on which returns the access token which can be used to authenticate with SharePoint. 当在消息中使用第一种类型时,bot会通过单击URL的地址进行响应,然后单击该URL返回可用于向SharePoint进行身份验证的访问令牌。 Format of URL is as below:
URL格式如下:
{spAuth_SiteUri}/_layouts/15/appredirect.aspx?client_id={spAuth_AppClientId}&redirect_uri={spAuth_RedirectUri}
Is there any way we can bypass this redirection and get token from back end? 有什么方法可以绕过此重定向并从后端获取令牌? Method which is used is below:
使用的方法如下:
GetClientContextWithContextToken
SharePoint Add-ins are authenticated against the SharePoint host. 针对SharePoint主机对SharePoint加载项进行身份验证。 You could create an add-in which itself hosts the webchat client.
您可以创建一个外接程序,该外接程序本身托管网络聊天客户端。 You can/could tweak web-chat to do additional stuff with SharePoint as needed from there.
您可以/可以根据需要调整Web聊天以使用SharePoint进行其他操作。 This would be opposed to the simple webchat in an iframe/webpart setup (which won't let you do what you need).
这与iframe / webpart设置中的简单网络聊天相反(后者无法让您做所需的事情)。
Please see the following links for more information. 请查看以下链接以获取更多信息。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.