Test-TppObject

SYNOPSIS

Test if an object exists

SYNTAX

DN (Default)

Test-TppObject -Path <String[]> [-ExistOnly] [-TppSession <TppSession>] [<CommonParameters>]

GUID

Test-TppObject -Guid <Guid[]> [-ExistOnly] [-TppSession <TppSession>] [<CommonParameters>]

DESCRIPTION

Provided with either a DN path or GUID, find out if an object exists.

EXAMPLES

EXAMPLE 1

$multDNs | Test-TppObject

Object Exists -------- ----- \VED\Policy\My folder1 True \VED\Policy\My folder2 False

Test for existence by Path

EXAMPLE 2

Test-TppObject -Path '\VED\Policy\My folder' -ExistOnly

Retrieve existence for only one object

PARAMETERS

-Path

DN path to object. Provide either this or Guid. This is the default if both are provided.

Type: String[]
Parameter Sets: DN
Aliases: DN

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

-Guid

Guid which represents a unqiue object. Provide either this or Path.

Type: Guid[]
Parameter Sets: GUID
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-ExistOnly

Only return boolean instead of Object and Exists list. Helpful when validating just 1 object.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

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

-TppSession

Session object created from New-TppSession method. The value defaults to the script session object $TppSession.

Type: TppSession
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: $Script:TppSession
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.

INPUTS

Path or Guid.

OUTPUTS

PSCustomObject will be returned with properties 'Object', a System.String, and 'Exists', a System.Boolean.

NOTES

http://venafitppps.readthedocs.io/en/latest/functions/Test-TppObject/

https://github.com/gdbarron/VenafiTppPS/blob/main/VenafiTppPS/Code/Public/Test-TppObject.ps1

https://docs.venafi.com/Docs/20.4SDK/TopNav/Content/SDK/WebSDK/r-SDK-POST-Config-isvalid.php?tocpath=Web%20SDK%7CConfig%20programming%20interface%7C_____25