0

Is there a web service that can list all Sharepoint Online top-level sites that exist in a tenant?

For example:

https://mytenant.sharepoint.com

Has

https://mytenant.sharepoint.com/sites/site1

and

https://mytenant.sharepoint.com/sites/site2

Is there a way to list site1 and site2 using a soap or rest web service?

If so, what permission is required?

Nicholas DiPiazza
  • 717
  • 2
  • 16
  • 42

1 Answers1

0

If you are looking for a way to get a list of the site collections, and if PowerShell is OK:

Get-SPOSite

https://docs.microsoft.com/en-us/powershell/module/sharepoint-online/?view=sharepoint-ps

Otherwise, I'm not aware of a direct REST query for a list of Site Collections.

You can use the search REST API and search for contentclass:sts_site. This is security trimmed, so you will only see the site collections you have permissions for. You can test this from a SharePoint search center to see if it works.

Mike Smith - MCT
  • 6,807
  • 2
  • 12
  • 21