May 24 2023 01:45 AM - edited May 24 2023 01:46 AM
Hi everyone,
I'm currently working on a project where I need to filter out Teams SharePoint channel sites when making a request to retrieve all sites using the GET /sites endpoint.
I have noticed that there doesn't seem to be a specific parameter in the properties that can be used to identify Teams sites. For example, when working with OneDrive, the URL contains "-my.xxx.com" as an identifier. Is there any way to filter out Teams sites?
One possible approach I have considered is listing all the channel names in Teams and then filtering out the sites that match those names. I have observed that the SharePoint web client can perform this kind of filtering. Is this functionality only available internally and not accessible through the Graph API? When I access a Teams SharePoint site, it displays the Teams logo, and these sites are not visible under "All Sites" in the SharePoint client.
Oct 19 2023 10:34 PM
Oct 20 2023 01:03 AM
@Samraj_krishnakumar Workaround is that, get all teams group name (ie. the teams sites name) with teams API. And then filter out the sites.
List all teams in Microsoft Teams for an organization - Microsoft Graph | Microsoft Learn