question

PhilHaack-9545 avatar image
0 Votes"
PhilHaack-9545 asked ·

Help me understand Bot Service User Ids for Teams

Hi, we're using Azure Bot Service and the Bot Framework SDK for C#. We noticed that the user IDs for Slack users are very different from MS Teams users. We don't understand what the components of the ID represent for Teams users.

For example, a slack user id with Azure Bot Service connected to Slack might look like: U112345:T1234567. The ID has two parts. The part before the : is their Slack User Id. The part after the : is the Id of the Slack Workspace (or Team).

With Microsoft Teams, the ID looks something like: 29:9a2e7BgFqeN2...UQpiXg. It looks like the left part is an integer and the right part is some sort of token string. What do these values represent?

Thanks!


office-teams-app-devazure-bot-service
· 1
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @PhilHaack-9545

According to your description, your issue is more related to development, which we do not support. I will remove "office-teams-windows-itpro" from your thread. Thanks for your understanding and patience!

1 Vote 1 ·

1 Answer

YutongTie-5848 avatar image
0 Votes"
YutongTie-5848 answered ·

Hi there,

Depending on the channel vendor, the intent of the ids is intended to be opaque such that you can't draw inferences from the content of the id's. In the case of both Teams and Slack those companies have chosen to provide different ID's to each application such that no two bots could correllate the id's.

In the case of Teams/Skype mechanically, 28/29 are sort of address spaces for id's (I think 28 might be Skype and 29 might be Teams, but it's more complex than that in practice. The best approach to identify the user is to have them log in with some sort of credentials (OAuth, AAD), and utilize that to determine who they are.

Hope this helps.

Regards,
Yutong

· 1 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

The best approach to identify the user is to have them log in with some sort of credentials (OAuth, AAD), and utilize that to determine who they are

How would I do that if the ID of the user in chat is opaque? How would I correlate a logged in user with the user in chat?

0 Votes 0 ·