when i give user id as 8:orgid:6272876c-3b81-48a2-86d0-5b1d03fc1600 i am getting below error
{
"CommunicationError": {
"Code": "BadRequest",
"Message": "The provided microsoft teams user id (8:orgid:6272876c-3b81-48a2-86d0-5b1d03fc1600) is invalid.",
"Details": []
}
}
when i give 6272876c-3b81-48a2-86d0-5b1d03fc1600 i am getting below error.
{
"CommunicationError": {
"Code": "Forbidden",
"Details": []
}
}
code snippet i am using :
const teamsParticipant:MicrosoftTeamsUserIdentifier = { microsoftTeamsUserId : "6272876c-3b81-48a2-86d0-5b1d03fc1600"};
const chatParticipant:ChatParticipant = {
id : teamsParticipant,
displayName: "Dev 66"
};
let participants: ChatParticipant[] = [];
participants.push(chatParticipant);
const createChatThreadOptions:CreateChatThreadOptions = {
participants : participants,
};
const createChatThreadRequest:CreateChatThreadRequest ={
topic : "Hello teams"
};
const createChatThreadResult:CreateChatThreadResult = await chatClient.createChatThread(createChatThreadRequest,createChatThreadOptions);
i am seeing chat in acs scope when i decode my acs access token:
"scp": 1024,
"csi": "1739251188",
"exp": 1739256777,
"rgn": "amer",
"tid": "e3a46007-31cb-4529-b8cc-1e59b97ebdbd",
"acsScope": "voip,chat",
also i went through the documentation teams interoperability at https://learn.microsoft.com/en-us/azure/communication-services/concepts/teams-interop i am seeing that for teams user chat is enabled via Graph api only. is this the reason why i am not able to create chat thread.