Get-TeamTargetingHierarchyStatus

Get the status of a hierarchy upload (see Set-TeamTargetingHierarchy)

Syntax

Get-TeamTargetingHierarchyStatus
   [-RequestId <String>]
   [-ApiVersion <String>]
   [<CommonParameters>]

Examples

Example 1

PS C:\> Set-TeamTargetingHierarchy -FilePath d:\hier.csv

Key       Value
---       -----
requestId c67e86109d88479e9708c3b7e8ff7217

PS C:\> Get-TeamTargetingHierarchyStatus -RequestId c67e86109d88479e9708c3b7e8ff7217

# When an error occurs, you will see the details in the ErrorMessage field.

Id              : c67e86109d88479e9708c3b7e8ff7217
Status          : Failed
LastKnownStatus : Validating
ErrorMessage    : 1 error(s) were found.
                  Error: InvalidTeamId
                  Descriptions:
                  TeamID in row 2 doesn't match a valid Group ID. Please view our documentation to learn how to get the proper Group ID for each team.
                  TeamID in row 3 doesn't match a valid Group ID. Please view our documentation to learn how to get the proper Group ID for each team.
                  TeamID in row 4 doesn't match a valid Group ID. Please view our documentation to learn how to get the proper Group ID for each team.
                  TeamID in row 5 doesn't match a valid Group ID. Please view our documentation to learn how to get the proper Group ID for each team.
                  TeamID in row 6 doesn't match a valid Group ID. Please view our documentation to learn how to get the proper Group ID for each team.
                  TeamID in row 7 doesn't match a valid Group ID. Please view our documentation to learn how to get the proper Group ID for each team.

LastUpdatedAt   : 2021-02-17T22:28:08.7832795+00:00
LastModifiedBy  : a145d7eb-b70d-4591-9455-6c87382a22b7
FileName        : hier1.csv

# When the hierarchy uploads and parses successfully, you will see this status.

Id              : c67e86109d88479e9708c3b7e8ff7217
Status          : Successful
LastKnownStatus :
ErrorMessage    :
LastUpdatedAt   : 2021-02-17T22:48:41.6664097+00:00
LastModifiedBy  : a145d7eb-b70d-4591-9455-6c87382a22b7
FileName        : hier.csv

Prompts for user credentials to connect and manage a Microsoft Teams environment.

Parameters

-ApiVersion

The version of the Hierarchy APIs to use. Valid values are: 1 or 2.

Currently only available in preview from version 6.6.1-preview. Specifying "-ApiVersion 2" will direct cmdlet requests to the newer version of the Hierarchy APIs. This integration is currently in preview/beta mode so customers should not try it on their production workloads but are welcome to try it on test workloads. This is an optional parameter and not specifying it will be interpreted as specifying "-ApiVersion 1", which will continue to direct cmdlet requests to the original version of the Hierarchy APIs until we upgrade production to v2, at which time we will set the default to 2. We do not expect this to have any impact on your cmdlet usage or existing scripts.

Type:String
Position:Named
Default value:1
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-RequestId

Specifies the ID returned by the Set-TeamTargetingHierarchy cmdlet. This parameter is optional and the status of the most recent upload will be retrieved.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False