Forum Discussion
BazVanDenDungen
May 20, 2022Copper Contributor
How do I get my teams bot to authenticate to a web service
I have a teams bot which I want to use as an interface for my service stack webservice however the token I have access to is not being accepted by the web service. I followed the "AAD SSO for ta...
Sayali-MSFT
Microsoft
May 20, 2022BazVanDenDungen-Please have look into this-
1.https://docs.microsoft.com/en-us/microsoftteams/platform/bots/how-to/authentication/add-authentication?tabs=dotnet%2Cdotnet-sample
2.https://docs.microsoft.com/en-us/azure/bot-service/rest-api/bot-framework-rest-connector-authentication?view=azure-bot-service-4.0
hope it's helpful.
1.https://docs.microsoft.com/en-us/microsoftteams/platform/bots/how-to/authentication/add-authentication?tabs=dotnet%2Cdotnet-sample
2.https://docs.microsoft.com/en-us/azure/bot-service/rest-api/bot-framework-rest-connector-authentication?view=azure-bot-service-4.0
hope it's helpful.
Sayali-MSFT
Microsoft
May 23, 2022BazVanDenDungen-Could you please confirm if your issue has resolved with above suggestion or still looking for any help?
- BazVanDenDungenMay 24, 2022Copper Contributor
Sayali-MSFT We managed to get our integration working by modifying our oath connection setting from api://<guid> to api://<guid>/access_as_user
The only thing we are missing now is that our jwt token appears to be missing the email address associated with the user.
- Sayali-MSFTMay 24, 2022
Microsoft
BazVanDenDungen-When a user asks the bot to do something that requires the bot to have the user logged in, the bot can use an OAuthPrompt to initiate retrieving a token for a given connection.When you start an OAuth prompt, it waits for a token response event, from which it will retrieve the user's token.
Ref Doc:-Add authentication to a bot in Bot Framework SDK - Bot Service | Microsoft Docs- Sayali-MSFTJun 22, 2022
Microsoft
Could you please confirm if your issue has resolved with above suggestion or still looking for any help?