botframework-sdk icon indicating copy to clipboard operation
botframework-sdk copied to clipboard

[MS Teams Channel] New ID format makes bot framework completely unusable for certain use cases.

Open james-lawrence opened this issue 9 years ago • 5 comments

The new ID format makes it impossible to integrate our application with the bot framework for msteams.

Part of our application relies on being able to send users within a company updates as specified by the company. This means we need to be able to locate user IDs and send the message to that user without the user having sent a message to our application before.

previously we could (although it was hacky) make it work by pulling a list of user IDs from o365 and do some simple string manipulations to send a messages to a user. Thursday night a change was pushed out to the ID format that is completely opaque. This makes it impossible for our application to use the bot framework.

new format:

"from": {
"id": "29:1xUE_8WVVQxzRRQw54AkdMuRMeIfaDgHB89Nfph2bAD_BPYuyi6ulw-r80Mhv4Q5p4G8lCViMyxScjYwMQo6uGg",
"name": "James Lawrence"
}

old format:

"from": {
"id": "8:orgid:c3ec28d6-7188-45ec-996a-1e9341a6e307",
"name": "James Lawrence"
}

james-lawrence avatar Jan 28 '17 09:01 james-lawrence

We are encrypting the userid now but it will be consistent within your bot code and therefore usable for such things as a key for storing user data, etc.

We will be releasing additional support around querying users, teams and channel information and that id will be used for that functionality.

As far as your specific use case, though, let me follow with the team to find the appropriate way to do this. Ultimately this sounds like Graph API - being able to query org-wide information, especially for users outside the Teams ecosystem - but I'll check.

RichMoeMSFT avatar Jan 29 '17 20:01 RichMoeMSFT

we are using the graph api currently to get the list of users, the problem is mapping those ids to these new ids.

james-lawrence avatar Jan 29 '17 21:01 james-lawrence

@james-lawrence could you solve this issue? Let us know if you need further help or updates from our side.

carlosscastro avatar Mar 09 '17 18:03 carlosscastro

its been managed. this is still an actual issue though. it won't be fixed until a roster is available and CreateConversation works.

james-lawrence avatar Mar 10 '17 20:03 james-lawrence

@james-lawrence How did you manage to construct user id? I am also using Graph API to fetch all users.

rohankulkarni21 avatar Mar 01 '18 16:03 rohankulkarni21