Forum Discussion
When obtaining meeting information using Graph API, excluded users are still searched as participant
LeeJinWoo - What API did you use to get the attendee report after removing participant?
The current problem is that the host "removed" a participant from a Teams chat room, rather than using the API, but when meeting information is retrieved through the API, the removed user is still included in the participant information.
- Prasad_Das-MSFTDec 29, 2023
Microsoft
LeeJinWoo - We tried below steps of adding and removing participants using PATCH api and we are getting correct participants list as follows:
1.Creating an online meeting with participants A & B.POST https://graph.microsoft.com/v1.0/users/cxxdef33-d7xx-444c-xx28-be1f95e6b6f2/onlineMeetings
{"startDateTime": "2023-12-29T14:30:34.2444915-07:00","endDateTime": "2023-12-29T15:00:34.2464912-07:00","subject": "User count Meeting","participants": {"attendees": [{"upn": "admin@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "ce9def33-d7fc-444c-8728-be1f95e6b6f2"}}},{"upn": "adelev@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "75f9fd6b-bebd-4039-b576-2c7c87b1f5b1"}}}]}}In result we have 2 participants
2. Then added another participant C to the existing meeting using PATCH function.
{"startDateTime": "2023-12-29T14:30:34.2444915-07:00","endDateTime": "2023-12-29T15:00:34.2464912-07:00","subject": "User count Meeting","participants": {"attendees": [{"upn": "admin@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "ce9def33-d7fc-444c-8728-be1f95e6b6f2"}}},{"upn": "adelev@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "75f9fd6b-bebd-4039-b576-2c7c87b1f5b1"}}},{"upn": "alexw@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "1dd50ba7-e5bd-46ea-b34e-80a415148de7"}}}]}}In result we have 3 participants
3. Then removed added participant C using PATCH function.
{"startDateTime": "2023-12-29T14:30:34.2444915-07:00","endDateTime": "2023-12-29T15:00:34.2464912-07:00","subject": "User count Meeting","participants": {"attendees": [{"upn": "admin@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "ce9def33-d7fc-444c-8728-be1f95e6b6f2"}}},{"upn": "adelev@M365x17798679.onmicrosoft.com","identity": {"user": {"id": "75f9fd6b-bebd-4039-b576-2c7c87b1f5b1"}}}]}}In result we have 2 participants as expected.- LeeJinWooJan 02, 2024Copper ContributorHi, Happy New Year.
In your third step guide, remove the last C user from the chat window of the meeting, not the API, and then GET the meeting information through the API.
In this case, user C still exists in the participant list.- Prasad_Das-MSFTJan 02, 2024
Microsoft
LeeJinWoo - We tried removing the participant manually and again ran the GET query using the meeting Id and can observe that its returning 3 participants.
This seems to be by design because the removed participant was part of the meeting and using that meeting id only, we are getting meeting details. So, its showing 3 participants.