Get-VBOOrganizationSite

In this article

    Short Description

    Returns organization sites.

    Syntax

    This cmdlet provides parameter sets that allow you to:

    • Get all organization sites of the specified organization.

    Get-VBOOrganizationSite -Organization <VBOOrganization> [-IncludePersonalSite] [-IncludeSearchSite] [-NotInJob] [-Recurse] [-LocationFilter {Cloud | OnPremises | Any}] [<CommonParameters>]

    • Get organization sites by the site URL.

    Get-VBOOrganizationSite -Organization <VBOOrganization> [-URL <string>] [-IncludePersonalSite] [-IncludeSearchSite] [-NotInJob] [-Recurse] [-LocationFilter {Cloud | OnPremises | Any}] [<CommonParameters>]

    • Get sub-level child sites of the specified parent organization site.

    Get-VBOOrganizationSite -Organization <VBOOrganization> [-ParentURL <string>] [-IncludePersonalSite] [-IncludeSearchSite] [-NotInJob] [-Recurse] [-LocationFilter {Cloud | OnPremises | Any}] [<CommonParameters>]

    Detailed Description

    This cmdlet returns Microsoft organization sites.

    Parameters

    Parameter

    Description

    Type

    Required

    Position

    Accept Pipeline Input

    Accept Wildcard Characters

    Organization

    Specifies an organization. The cmdlet will return organization sites of the specified organization.

    Accepts the VBOOrganization object.

    To get this object, run the Get-VBOOrganization cmdlet.

    True

    Named

    True (ByValue)

    False

    NotInJob

    Defines that the cmdlet will return sites that are not assigned to any of the backup jobs.

    Note: Sites that are backed up by the EntireOrganization job are considered to be NotInJob as well.

    SwitchParameter

    False

    Named

    False

    True

    ParentURL

    Specifies parent organization site URL.

    If the Recurse parameter is not used, the cmdlet will return one sub-level child site of the organization site with this URL.

    String

    False

    Named

    False

    False

    Recurse

    Defines that the cmdlet will return all sub-level child sites.

    SwitchParameter

    False

    Named

    False

    False

    LocationFilter

    Note: Use this parameter for organizations of the Hybrid type.

    Specifies an organization site location type:

    • Cloud
    • OnPremises
    • Any

    The cmdlet will return organization sites of this location type.

    VBOSiteLocationFilters

    False

    Named

    False

    False

    URL

    Specifies the organization site URL.

    If the Recurse parameter is not used, the cmdlet will return the organization site with this URL.

    String

    False

    Named

    False

    False

    IncludePersonalSite

    Defines that the cmdlet will return personal sites along with the other organization sites.

    SwitchParameter

    False

    Named

    False

    False

    IncludeSearchSite

    Defines that the cmdlet will return search sites along with the other organization sites.

    SwitchParameter

    False

    Named

    False

    False

    <CommonParameters>

    This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About CommonParameters section of Microsoft Docs.

    Examples

    Example 1. Getting All Unprocessed Sites in Microsoft Organization

    This example shows how to get all organization sites in the ABC organization that are not backed up by any backup job.

    $org = Get-VBOOrganization -Name "ABC"

    Get-VBOOrganizationSite -Organization $org -NotInJob -IncludePersonalSite

    Perform the following steps:

    1. Run the Get-VBOOrganization cmdlet with the Name parameter to get the organization with the name ABC. Save the result to the $org variable.
    2. Run the Get-VBOrganizationSite cmdlet with the $org variable to get all organization sites of an organization with the name ABC. Use the NotInJob parameter to get only organization sites that are not specifically assigned to any backup job. Use the IncludePersonalSite parameter to get personal sites as well.

    Example 2. Getting Specific Site Including All Child Sites

    This example shows how to get an organization site under a certain URL and all of its child sites.

    $org = Get-VBOOrganization -Name "ABC"

    $siteUrl = "https://exampleorganization.sharepoint.com/sites/exampleparentsite"

    Get-VBOOrganizationSite -Organization $org -URL $siteUrl -Recurse

    Perform the following steps:

    1. Run the Get-VBOOrganization cmdlet with the Name parameter to get the organization with the name ABC. Save the result to the $org variable.
    2. Save a certain SharePoint organization site URL address to the $siteUrl variable.
    3. Run the Get-VBOrganizationSite cmdlet with the $org variable. Specify the $siteUrl variable as the URL parameter value to get an organization site with a specified URL. Use the Recurse parameter to also get all sub-levels child sites.

    Example 3. Getting Only Child Sites

    This example shows how to get only one sub-level child site of the parent organization site $parentSite.

    $org = Get-VBOOrganization -Name "ABC"

    $parentSite = "https://exampleorganization.sharepoint.com/sites/exampleparentsite"

    Get-VBOOrganizationSite -Organization $org -ParentURL $parentSite

    Perform the following steps:

    1. Run the Get-VBOOrganization cmdlet with the Name parameter to get the organization with the name ABC. Save the result to the $org variable.
    2. Save a certain SharePoint organization site URL address to the $parentSite variable.
    3. Run the Get-VBOrganizationSite cmdlet with the $org variable. Specify the $parentSite variable as the ParentURL parameter value to get one sub-level child site of the $parentSite organization site.

    Related Commands

    Get-VBOOrganization