< Back

Get-JCPolicy

Thu Jan 16, 2020 8:52 am

NAME Get-JCPolicy



SYNOPSIS

Returns all JumpCloud Policies within a JumpCloud tenant.





SYNTAX

Get-JCPolicy [-PolicyID] <System.String> [-ByID] [<CommonParameters>]



Get-JCPolicy [-Name <System.String>] [<CommonParameters>]





DESCRIPTION

The Get-JCPolicy function returns all information describing JumpCloud policies within a JumpCloud tenant.





PARAMETERS

-ByID <System.Management.Automation.SwitchParameter>

Use the -ByID parameter when you want to query a specific policy. The -ByID SwitchParameter will set the

ParameterSet to 'ByID' which queries one JumpCloud policy at a time.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-Name <System.String>

The Name of the JumpCloud policy you wish to query.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-PolicyID <System.String>

The PolicyID of the JumpCloud policy you wish to query.



Required? true

Position? 0

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

System.String







OUTPUTS

System.Object







NOTES









-------------------------- Example 1 --------------------------



PS C:\\> Get-JCPolicy



Returns all JumpCloud Policies populated within the Policies section of the JumpCloud admin console.

-------------------------- Example 2 --------------------------



PS C:\\> Get-JCPolicy -PolicyID 123456789



Returns the policy associated to the id of 123456789.

-------------------------- Example 3 --------------------------



PS C:\\> Get-JCPolicy -Name 'HelloWorld'



Returns the HelloWorld policy.



RELATED LINKS

Online Version: https://github.com/TheJumpCloud/support ... t-JCPolicy