Forum Discussion

puri18's avatar
puri18
Copper Contributor
May 06, 2022

Getting onTurnError using the sample teams bot auth from github

Hi, I've been trying to make the sample bot authentication app provided in the following github repo work:

BotBuilder-Samples/samples/javascript_nodejs/46.teams-auth at main · microsoft/BotBuilder-Samples · GitHub

 

I have followed all the steps indicated but I just can't make it work properly. I have been getting an onTurnError every time I try to send a message to the bot. Here's the error in the terminal:

Here's what the bot sends me in in teams chat when I receive this error:

 

I assume that if this works properly and I type anything, it should show the prompt to sign in but it never does.

The logout dialog seems to work when i send "logout" though.

 

I am running this with ngrok and have put the ngrok url in the messaging endpoint of my bot like this:
<ngrok_url>/api/messages

 

I run this command in ngrok: ngrok http -host-header=rewrite 3978


Please help. I'm not sure what to do anymore.

 

  • We are checking this at our end, we will setup the sample locally and get back to you.
    • puri18's avatar
      puri18
      Copper Contributor
      Hi, any updates on this? thank you
      • Nivedipa-MSFT's avatar
        Nivedipa-MSFT
        Icon for Microsoft rankMicrosoft
        puri18 - We have tested this sample. Before adding OAuth Connection Settings we also got onTurnError. But after adding OAuth Connection Settings it was working fine at our end.
        Could you please add OAuth Connection Settings and check again.

Resources