13,723 questions
Why does the graph API return a ReadableStream?
Anonymous
export async function createTeamChat(displayName) {
const team = {
'******@odata.bind': "https://graph.microsoft.com/v1.0/teamsTemplates('standard')",
displayName: `Jurimesh Support - ${displayName}`,
description: 'This team is for support and questions about Jurimesh.',
visibility: 'Private',
members: [{
'@odata.type': '#microsoft.graph.aadUserConversationMember',
roles: ['owner'],
'******@odata.bind': `https://graph.microsoft.com/v1.0/users/${DEFAULT_MICROSOFT_CHAT_OWNERS[0]}`
}],
channels: [
{
displayName: 'Announcements',
description: 'This channel is for communication and announcements regarding Jurimesh.',
},
{
displayName: 'Support',
description: 'This channel is for support and questions about Jurimesh.',
}
]
};
return await graphClient.api('/teams')
.post(team);
}
This function returns a Readable Stream. it should return a json when awaited as described in the API specs of creating a team. Why is this happening?
Microsoft Security | Microsoft Graph
Sign in to answer