I have a message extension app for MS TEAMS. This app will be preinstalled inside some organization. I should get members of any conversation type. There is a way via a graph https://graph.microsoft.com/v1.0/groups/{group-id-for-teams}/members. I use application permission here.
But it looks like I can get users only for "group" (a team is inside Teams), which has channels. I got 4 types of conversation type from ChannelAccount (namespace Microsoft.Bot.Schema):
Also, there is bool isGroup property.
How can I get members of a specific chat, which can be any conversation type?
You can use this set of endpoints to access both group chat and channel members. You don't technically need to get the "members" of a 1-1 chat, because it is only individual users (if you add a 3rd user, for instance, it will switch to becoming a group chat, I think). If you -do- want to get the -existence- of these 1-1 chats, you can use this endpoint. Note that these are both BETA endpoints, so some caveats apply.