Get-VSTeamArea
SYNOPSIS
Gets the area node for a given area path.
SYNTAX
ByPath (Default)
Get-VSTeamArea [-Path <String>] [-Depth <Int32>] -ProjectName <String> [<CommonParameters>]
ByIds
Get-VSTeamArea [-Id <Int32[]>] [-Depth <Int32>] -ProjectName <String> [<CommonParameters>]
DESCRIPTION
Gets the area node for a given area path.
EXAMPLES
Example 1
Get-VSTeamArea -Path "Features\Login" -ProjectName "MyProject"
This command retrieves the area node corresponding to the "Login" area under the "Features" path in the project "MyProject".
Example 2
Get-VSTeamArea -Id 45 -ProjectName "DevOpsProject"
In this example, the area node with the ID 45 within the "DevOpsProject" is fetched.
Example 3
Get-VSTeamArea -Depth 2 -Path "Features" -ProjectName "MyProject"
This example demonstrates how to retrieve the area node for the "Features" path in the project "MyProject", including its children up to a depth of 2.
Example 4
$areas = Get-VSTeamArea -ProjectName "MyProject"
$areas | Where-Object { $_.Name -like "*UI*" }
This command fetches all area nodes in the "MyProject" and then filters out areas that have a name containing the word "UI".
PARAMETERS
-Depth
Depth of children to fetch.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Path
Path of the classification node.
Type: String
Parameter Sets: ByPath
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Id
Integer classification nodes ids.
Type: Int32[]
Parameter Sets: ByIds
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-ProjectName
Specifies the team project for which this function operates.
You can tab complete from a list of available projects.
You can use Set-VSTeamDefaultProject to set a default project so you do not have to pass the ProjectName with each call.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
INPUTS
OUTPUTS
System.Object
NOTES
This is a wrapper function for Get-VSTeamClassificationNode
Prerequisites:
Set the account and version that all calls will use with Set-VSTeamAccount. Default version sets to API version 3.0 (TFS2017) if not manually set.
tips:
- check called version of the API with Get-VSTeamAPIVersion or Get-VSTeamInfo
- use Set-VSTeamDefaultProject to set default project for every call
- use Set-VSTeamDefaultAPITimeout to change the default timeout of 60 seconds for all calls.
- use Profiles to load an account and the correct version