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?

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.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.