Get-IvantiOrganizationUnit
SYNOPSIS
Retrieves organizational units from Ivanti ITSM.
SYNTAX
RecID (Default)
Get-IvantiOrganizationUnit -RecID <String> [-isDeleted] [-top <Int32>] [-customFields <String>] [-allFields]
[<CommonParameters>]
Search
Get-IvantiOrganizationUnit -search <String> [-isDeleted] [-top <Int32>] [-customFields <String>] [-allFields]
[<CommonParameters>]
Name
Get-IvantiOrganizationUnit -Name <String> [-isDeleted] [-top <Int32>] [-customFields <String>] [-allFields]
[<CommonParameters>]
DESCRIPTION
Retrieves organizational units from Ivanti ITSM based on specified parameters such as record ID, search criteria, name, and other optional criteria. Allows selecting specific fields, filtering by deleted status, and limiting the number of results.
EXAMPLES
EXAMPLE 1
Retrieves the organizational unit with the record ID 'abc123'.
EXAMPLE 2
Retrieves the organizational unit with the search criteria 'OrgUnit123'.
EXAMPLE 3
Retrieves the deleted organizational unit with the name 'IT Department'.
EXAMPLE 4
Retrieves the top 10 organizational units including custom fields 'Field1' and 'Field2'.
PARAMETERS
-RecID
The record ID of the organizational unit to be retrieved.
Type: String
Parameter Sets: RecID
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-search
The search criteria to find the organizational unit to be retrieved.
Type: String
Parameter Sets: Search
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Name
The name of the organizational unit to be retrieved.
Type: String
Parameter Sets: Name
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-isDeleted
Switch to indicate if only deleted organizational units should be retrieved.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-top
The maximum number of results to return.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False
-customFields
A comma-separated list of custom fields to be included in the result.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-allFields
Switch to indicate if all fields should be returned.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
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.