Get-VETPost

Short Description

Returns Microsoft Teams team channel posts.

Product: Veeam Backup for Microsoft 365

Product Edition: Community, Rental License, Subscription License

Syntax

This cmdlet provides the following parameter sets:

  • QueryByChannelParameterSet

    Get-VETPost -Channel <VETChannel> [-Query <String>] [-Recurse] [<CommonParameters>]

  • QueryByPostParameterSet

    Get-VETPost -ParentPost <VETPost> [-Query <String>] [-Recurse] [<CommonParameters>]

  • QueryByOrganizationParameterSet

    Get-VETPost [-Query <String>] -Organization <VETOrganization[]> [<CommonParameters>]

  • QueryByTeamParameterSet

    Get-VETPost [-Query <String>] -Team <VETTeam> [<CommonParameters>]

Detailed Description

This cmdlet returns posts published in Microsoft Teams team channels. You can get parent and child posts from the following backed-up sources:

  • Microsoft Teams organization
  • Microsoft Teams team
  • Microsoft Teams channel

Parameters

Parameters

Parameter

Description

Type

Required

Position

Accept Pipeline Input

Channel

Specifies a Microsoft Teams team channel. The cmdlet will return posts from this channel.

Accepts the VETChannel object. To get this object, run the Get-VETChannelReturns Microsoft Teams team channels. cmdlet.

VETChannel

True

Named

True (ByValue)

Organization

Specifies an array of Microsoft Teams organizations. The cmdlet will return posts from these organizations.

Accepts the VETOrganization[] object. To get this object, run the Get-VETOrganizationReturns Microsoft Teams organizations added to Veeam Backup for Microsoft 365. cmdlet.

VETOrganization[]

True

Named

True (ByValue)

ParentPost

Specifies a parent post. The cmdlet will return child posts of this parent post.

Accepts the VETPost object. To get this object, run the Get-VETPost cmdlet.

VETPost

True

Named

True (ByValue)

Query

Specifies a query string for post search. The cmdlet will return posts that match the search query from the specified organization, team, channel or parent post.

For more information, see the Appendix A. Item Search Parameters section of the Veeam Backup for Microsoft 365 User Guide.

String

False

Named

False

Recurse

Defines that the cmdlet will return the specified parent post and all of its child posts.

Default: False

SwitchParameter

False

Named

False

Team

Specifies a Microsoft Teams team. This cmdlet will return posts from this team.

Accepts the VETTeam object. To get this object, run the Get-VETTeamReturns Microsoft Teams teams. cmdlet.

VETTeam

True

Named

True (ByValue)

<CommonParameters>

This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About Common Parameters section of Microsoft Learn.

Output Object

The cmdlet returns the VETPost[] array that contains Microsoft Teams posts.

Examples

Get-VETPostExample 1. Getting Posts from Channel

This example shows how to get all posts from the General channel.

$session = Get-VBOTeamsItemRestoreSession

$org = Get-VETOrganization -Session $session -Name "ABC*"

$team = Get-VETTeam -Organization $org -DisplayName "IT"

$channel = Get-VETChannel -Team $team -DisplayName "General"

Get-VETPost -Channel $channel

Perform the following steps:

  1. Get the channel:

    1. Run the Get-VBOTeamsItemRestoreSessionReturns active restore sessions started to perform operations with backed-up Microsoft Teams items. cmdlet. Save the result to the $session variable.
    2. Run the Get-VETOrganizationReturns Microsoft Teams organizations added to Veeam Backup for Microsoft 365. cmdlet. Set the $session variable as the Session parameter value. Specify the Name parameter value. Use the * wildcard character to substitute the timestamp. Save the result to the $org variable.
    3. Run the Get-VETTeamReturns Microsoft Teams teams. cmdlet. Set the $org variable as the Organization parameter value. Specify the DisplayName parameter value. Save the result to the $team variable.
    4. Run the Get-VETChannelReturns Microsoft Teams team channels. cmdlet. Set the $team variable as the Team parameter value. Specify the DisplayName parameter value. Save the result to the $channel variable.
  2. Run the Get-VETPost cmdlet. Set the $channel variable as the Channel parameter value.

Get-VETPostExample 2. Getting Posts from Parent Post

This example shows how to get channel posts under the Announcement parent post.

$session = Get-VBOTeamsItemRestoreSession

$org = Get-VETOrganization -Session $session -Name "ABC*"

$post = Get-VETPost -Organization $org -Query "subject: announcement"

Get-VETPost -ParentPost $post

Perform the following steps:

  1. Get the parent post:

    1. Run the Get-VBOTeamsItemRestoreSessionReturns active restore sessions started to perform operations with backed-up Microsoft Teams items. cmdlet. Save the result to the $session variable.
    2. Run the Get-VETOrganizationReturns Microsoft Teams organizations added to Veeam Backup for Microsoft 365. cmdlet. Set the $session variable as the Session parameter value. Specify the Name parameter value. Use the * wildcard character to substitute the timestamp. Save the result to the $org variable.
    3. Run the Get-VETPost cmdlet. Set the $org variable as the Organization parameter value. Specify the Query parameter value. Save the result to the $post variable.
  2. Run the Get-VETPost cmdlet. Set the $post variable as the ParentPost parameter value.

Get-VETPostExample 3. Getting Posts from Organization

This example shows how to get channel posts from the ABC organization.

$session = Get-VBOTeamsItemRestoreSession

$org = Get-VETOrganization -Session $session -Name "ABC*"

Get-VETPost -Organization $org

Perform the following steps:

  1. Get the organization:

    1. Run the Get-VBOTeamsItemRestoreSessionReturns active restore sessions started to perform operations with backed-up Microsoft Teams items. cmdlet. Save the result to the $session variable.
    2. Run the Get-VETOrganizationReturns Microsoft Teams organizations added to Veeam Backup for Microsoft 365. cmdlet. Set the $session variable as the Session parameter value. Specify the Name parameter value. Use the * wildcard character to substitute the timestamp. Save the result to the $org variable.
  2. Run the Get-VETPost cmdlet. Set the $org variable as the Organization parameter value.

Get-VETPostExample 4. Getting Posts from Team

This example shows how to get channel posts from the IT team.

$session = Get-VBOTeamsItemRestoreSession

$org = Get-VETOrganization -Session $session -Name "ABC*"

$team = Get-VETTeam -Organization $org -DisplayName "IT"

Get-VETPost -Team $team

Perform the following steps:

  1. Get the team:

    1. Run the Get-VBOTeamsItemRestoreSessionReturns active restore sessions started to perform operations with backed-up Microsoft Teams items. cmdlet. Save the result to the $session variable.
    2. Run the Get-VETOrganizationReturns Microsoft Teams organizations added to Veeam Backup for Microsoft 365. cmdlet. Set the $session variable as the Session parameter value. Specify the Name parameter value. Use the * wildcard character to substitute the timestamp. Save the result to the $org variable.
    3. Run the Get-VETTeamReturns Microsoft Teams teams. cmdlet. Set the $org variable as the Organization parameter value. Specify the DisplayName parameter value. Save the result to the $team variable.
  2. Run the Get-VETPost cmdlet. Set the $team variable as the Team parameter value.

Page updated 2026-08-20

Page content applies to build 8.5.0.1014