Get-PnPLabel
SYNOPSIS
Gets the Office 365 retention label/tag of the specified list or library (if applicable)
SYNTAX
Get-PnPLabel [-List <ListPipeBind>] [-Raw] [-Connection <PnPConnection>]
DESCRIPTION
Allows to retrieve all retention labels for current site or list. Use Raw
option if you want will include more detailed information regarding labels.
EXAMPLES
EXAMPLE 1
Get-PnPLabel
Returns all retention labels for the current web
EXAMPLE 2
Get-PnPLabel -List "Demo List" -ValuesOnly
This gets the retention label which is set to a list or a library
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
-List
The ID or Url of the list
Type: ListPipeBind
Parameter Sets: (All)
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False
-Raw
If provided, the results will be returned as values instead of in written text and will include more detailed information
Type: SwitchParameter
Parameter Sets: (All)
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False