Table of Contents

Get-PnPTerm

SYNOPSIS

Returns a Term Store Term.

SYNTAX

By Term Id

Get-PnPTerm -Identity <TaxonomyTermPipeBind> [-TermStore <TaxonomyTermStorePipeBind>]
 [-IncludeChildTerms] [-Connection <PnPConnection>] [-Includes <String[]>] 

By Term Name

Get-PnPTerm -TermSet <TaxonomyTermSetPipeBind> -TermGroup <TaxonomyTermGroupPipeBind>
 [-Identity <TaxonomyTermPipeBind>] [-TermStore <TaxonomyTermStorePipeBind>] [-Recursive]
 [-IncludeChildTerms] [-ParentTerm <TaxonomyTermPipeBind>] [-IncludeDeprecated]
 [-Connection <PnPConnection>] [-Includes <String[]>] 

DESCRIPTION

Retries a Term Store Term.

EXAMPLES

EXAMPLE 1

Get-PnPTerm -TermSet "Departments" -TermGroup "Corporate"

Returns all term in the termset "Departments" which is in the group "Corporate" from the site collection termstore

EXAMPLE 2

Get-PnPTerm -Identity "Finance" -TermSet "Departments" -TermGroup "Corporate"

Returns the term named "Finance" in the termset "Departments" from the termgroup called "Corporate" from the site collection termstore

EXAMPLE 3

Get-PnPTerm -Identity ab2af486-e097-4b4a-9444-527b251f1f8d -TermSet "Departments" -TermGroup "Corporate"

Returns the term named with the given id, from the "Departments" termset in a term group called "Corporate" from the site collection termstore

EXAMPLE 4

Get-PnPTerm -Identity "Small Finance" -TermSet "Departments" -TermGroup "Corporate" -Recursive

Returns the term named "Small Finance", from the "Departments" termset in a term group called "Corporate" from the site collection termstore even if it is a subterm below "Finance"

EXAMPLE 5

$term = Get-PnPTerm -Identity "Small Finance" -TermSet "Departments" -TermGroup "Corporate" -Includes Labels
$term.Labels

Returns all the localized labels for the term named "Small Finance", from the "Departments" termset in a term group called "Corporate"

EXAMPLE 6

Get-PnPTerm -Identity "Small Finance" -TermSet "Departments" -TermGroup "Corporate" -Recursive -IncludeDeprecated

Returns the deprecated term named "Small Finance", from the "Departments" termset in a term group called "Corporate" from the site collection termstore even if it is a subterm below "Finance"

PARAMETERS

-Connection

Optional connection to be used by the cmdlet. Retrieve the value for this parameter by either specifying -ReturnConnection on Connect-PnPOnline or by executing Get-PnPConnection.

Type: PnPConnection
Parameter Sets: (All)

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

-Identity

The Id or Name of a Term

Type: TaxonomyTermPipeBind
Parameter Sets: By Term Id

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Type: TaxonomyTermPipeBind
Parameter Sets: By Term Name

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

-IncludeChildTerms

Includes the hierarchy of child terms if available

Type: SwitchParameter
Parameter Sets: (All)

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

-Recursive

Find the first term recursively matching the label in a term hierarchy.

Type: SwitchParameter
Parameter Sets: (All)

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

-TermGroup

Name of the termgroup to check.

Type: TaxonomyTermGroupPipeBind
Parameter Sets: By Term Name

Required: True
Position: 0
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False

-TermSet

Name of the termset to check.

Type: TaxonomyTermSetPipeBind
Parameter Sets: By Term Name

Required: True
Position: 0
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False

-TermStore

Term store to use; if not specified the default term store is used.

Type: TaxonomyTermStorePipeBind
Parameter Sets: (All)

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

-ParentTerm

The Id or Name of the term to look for the term specified through -Identity under. Use this to retrieve a child term by its name when that name is not unique within the term set. Only taken into account when -Identity is also specified.

Type: TaxonomyTermPipeBind
Parameter Sets: By Term Name

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

-IncludeDeprecated

Includes the deprecated terms if available.

Type: SwitchParameter
Parameter Sets: By Term Name

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

-Includes

Optionally allows properties to be retrieved for the returned terms which are not included in the response by default

Type: String[]
Parameter Sets: (All)

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

Microsoft 365 Patterns and Practices