简体   繁体   中英

How to get user name on Microsoft Bot Framework?

I am using Microsoft Bot Framework. How to get user name of user when they are chatting with Microsoft Bot on Microsoft Teams.I am using bot builder and node.js

You can probably get the name of the person using:

session.message.address.user.name

Though you may have to check that, as different channel exposes different kind of data to the framework. Also you can have a look in the channelData field as well. It contains data specific to the channel. You can find channel data using:

session.message.source

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