简体   繁体   中英

Using User Token obtained from Azure Bot to get an access token to act as an On-Behalf-Of token

I have an Azure bot that prompts the user to login with their username and password. From this, I am able to obtain an authorization code. I would like to use this code to retrieve an on-behalf-of access token, which I'll use as a bearer token to authenticate my api calls to another web application.

The web application which I want to make api calls to also requires authentication to the Azure Active Directory. How would I go about exchanging the authorization code obtained from Azure Bot to an OBO access token?

There is no need to exchanging the token obtained from Azure Bot. If you want to access your another web application from Azure Bot, just set the resource as api://{api id} ( V1.0 ) or set the scope as api://{api id}/.default ( V2.0 ).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM