How to exclude Public sites from SharePoint Online Tenant

Copper Contributor

Dear All,

 

We have a requirement to exclude the Public group sites in the SharePoint Online Tenant through search query text (/_api/search/query?querytext='contentclass:STS_Site)

and display all other site collections.  

 

We have tried to exclude it by adding ‘-WebTemplate:GROUP’ but it is not displaying ‘private groups’ too.

 

Kindly share your suggestions if we can exclude the Public group sites from SP Online Tenant.

 

Yarliphani_0-1634050155734.png

 

Regards,

Phani Yarlagadda

0 Replies