Forum Discussion

Debpratim's avatar
Debpratim
Copper Contributor
Aug 18, 2021
Solved

Capture Logged in User's Mail

I am saving feedback data using

session.saveFeedback() method but I also want the logged in users email to be saved. How can i get that information .Thanks in advance.@Adam Walker 

 

  • Debpratim Look inside the 

    session.message

    variable in the Health Bot scenario (you can print it in a statement step). This might have the information you need. 

3 Replies

  • Adam Walker's avatar
    Adam Walker
    Brass Contributor

    Debpratim - It depends on how you are implementing the authentication, but I assume you are doing the authentication before you load the bot (for example, you have a portal experience and then you show the webchat) you should have access to the login details in that page. You should send the email as part of the custom arguments that invokes the bot. Anything you pass in those arguments is available in the scenarioArgs in the scenario that you build in Health Bot. See this doc:
    https://docs.microsoft.com/en-us/azure/health-bot/integrations/programmatic_invocation

    • Debpratim's avatar
      Debpratim
      Copper Contributor

      Adam Walker Thanks Adam , for now i want to publish the bot in teams channel and and want the currently logged in user details to be captured. Any ways to achieve this

      • Adam Walker's avatar
        Adam Walker
        Brass Contributor

        Debpratim Look inside the 

        session.message

        variable in the Health Bot scenario (you can print it in a statement step). This might have the information you need. 

Resources