Help Center
Choose product document...
Veeam Backup for Microsoft Office 365 2.0
PowerShell Reference

Get-VESPItem

Short Description

Returns SharePoint items.

Syntax

This cmdlet provides 4 parameter sets.

  • For getting items from a SharePoint organization:

Get-VESPItem [-Organization] <VESPOrganization[]> [-Query <string>]  [<CommonParameters>]

  • For getting items from a SharePoint site:

Get-VESPItem [-Site] <VESPSite> [-Query <string>]  [<CommonParameters>]

  • For getting items from a SharePoint list:

Get-VESPItem [-List] <VESPList> [-Query <string>] [-Recurse]  [<CommonParameters>]

  • For getting items from a parent item:

Get-VESPItem [-ParentItem] <VESPItem> [-Query <string>] [-Recurse]  [<CommonParameters>]

Detailed Description

This cmdlet returns SharePoint items. You can search the organization, site or list to get the needed item or to get all of the children of a specific item.

Parameters

Parameter

Description

Required

Position

Accept
Pipeline
Input

Accept
Wildcard
Characters

Organization

Specifies an organization. The cmdlet will return document library from this organization.

True

0

True (ByValue)

False

List

Specifies a SharePoint List. This cmdlet will return a SharePoint item from this list.

True

0

True (ByValue)

False

ParentItem

Specifies a parent item. The cmdlet will return only one sub-level child items for this item.

True

0

True (ByValue)

False

Query

Allows to use keywords for item search. The cmdlet will return items that match the search query from the specified database, site, list or item.

False

Named

False

True

Recurse

Indicates that the cmdlet will return items from all subfolders of the specified parent folder.

False

Named

False

False

Site

Specifies the name of the SharePoint site. This cmdlet will return a SharePoint item from the specified SharePoint site

True

0

True (ByValue)

False

<CommonParameters>

This cmdlet supports Microsoft PowerShell common parameters. For more information about common parameters, see http://go.microsoft.com/fwlink/p/?LinkID=113216.

Example 1

This example shows how to get an item from a specific organization with a name "ABC".

  1. Run Get-VBOSharePointItemRestoreSession to get the active restore session. Save the result to the $session variable.
  2. Run Get-VESPOrganization with the $session variable and a Name parameter to get the SharePoint organization with a name "ABC". Save the result to the $organization variable.
  3. Run Get-VESPItem with the $organization variable and enter a value for a Query parameter to get a SharePoint item.

PS C:\PS> $session = Get-VBOSharePointItemRestoreSession

PS C:\PS> $organization = Get-VESPOrganization -Session $session -Name "ABC"

PS C:\PS> Get-VESPItem -Organization $organization -Query

Example 2

This example shows how to get an item from a specific SharePoint site with a name "Team Site".

  1. Run Get-VBOSharePointItemRestoreSession to get the active restore session. Save the result to the $session variable.
  2. Run Get-VESPOrganization with the $session variable and a Name parameter to get the SharePoint organization with a name "ABC". Save the result to the $organization variable.
  3. Run Get-VESPSite with the $organization variable and a Name parameter to get a SharePoint site with a name "Team Site". Save the result to the $site variable.
  4. Run Get-VESPItem with the $site variable and enter a value for a Query parameter to get a SharePoint item.

PS C:\PS> $session = Get-VBOSharePointItemRestoreSession

PS C:\PS> $organization = Get-VESPOrganization -Session $session -Name "ABC"

PS C:\PS> $site = Get-VESPSite -Organization $organization -Name "Team Site"

PS C:\PS> Get-VESPItem -Site $site -Query

Example 3

This example shows how to get an item from a specific SharePoint list with a name "Color names list".

  1. Run Get-VBOSharePointItemRestoreSession to get the active restore session. Save the result to the $session variable.
  2. Run Get-VESPOrganization with the $session variable and a Name parameter to get the SharePoint organization with a name "ABC". Save the result to the $organization variable.
  3. Run Get-VESPList with the $organization variable and and Name parameter to get a SharePoint list with a name "Color names list". Save the result to the $list variable.
  4. Run Get-VESPItem with the $list variable and enter a value for a Query parameter to get a SharePoint item.

PS C:\PS> $session = Get-VBOSharePointItemRestoreSession

PS C:\PS> $organization = Get-VESPOrganization -Session $session -Name "ABC"

PS C:\PS> Get-VESPList -Organization $organization -Name "Color names list"

PS C:\PS> Get-VESPItem -List $list -Query

Example 4

This example shows how to get children items for an item with a name "document.txt".

  1. Run Get-VBOSharePointItemRestoreSession to get the active restore session. Save the result to the $session variable.
  2. Run Get-VESPOrganization with the $session variable and a Name parameter to get the SharePoint organization with a name "ABC". Save the result to the $organization variable.
  3. Run Get-VESPItem with the $organization variable and enter a "document.txt" value for a Query parameter to get a SharePoint item with a name "document.txt". Save result to the $parentItem variable.
  4. Run Get-VESPItem with the $parentDocument variable and Recurse parameter to get children of a SharePoint item with a name "document.txt".

PS C:\PS> $session = Get-VBOSharePointItemRestoreSession

PS C:\PS> $organization = Get-VESPOrganization -Session $session -Name "ABC"

PS C:\PS> $parentItem = Get-VESPItem -Organization $organization -Query "document.txt"

PS C:\PS> Get-VESPItem -ParentItem $parentItem -Recurse

Veeam Large Logo

User Guide

RESTful API Reference

PowerShell Reference