Get-CUActionSignature: Retrieve Action Parameters
    • Dark
      Light
    • PDF

    Get-CUActionSignature: Retrieve Action Parameters

    • Dark
      Light
    • PDF

    Article Summary

    You can use the Get-CUActionSignature cmdlet to obtain a list of parameters associated with a particular action. This command is helpful because it allows you to examine an action and determine which parameters can be provided to it in JSON format. The parameters included in the list are

    • Input parameters required by the action
    • Output parameters which return the results of the action

    Prerequisites

    • ControlUp version 8.8 or higher

    Syntax

    Get-CUActionSignature [-ActionId] <string>  [<CommonParameters>]
    

    Input Parameters

    The script parameters are defined in an argument array, where each parameter is identified by its index, starting from zero. For example, the first parameter is referred to as arg_0, the second parameter is arg_1, and so on.
    image.png

    Input Parameters

    KeyDescription
    agentIdInternal Use. The remote machine to run the action on
    argCommand line argument for the action
    credsCredential set

    Output Parameters

    KeyDescription
    executionStatusCurrent status of the action execution. Possible values are
    • Waiting (0)
    • Running (1)
    • Aborted (2)
    • Timeout (3)
    • Success (4)
    • Error (5)
    • ExecutionError (6)
    exitCodeReturns the exit code for the action
    executionStartTimeEpoch timestamp of the start time
    executionEndTimeEpoch timestamp of the end time
    stdErrShows the error (if thrown by the action)
    stdOutReturns the output as you would see in the script output

    Examples

    Example 1 - Retrieve the action signature for the Universal EUC Sync Script

    One of our most powerful scripts is the Universal EUC Sync Script which requires a couple of input parameters.

    1. Retrieve the actionID:
    $availableactions = Get-CUAvailableActions
    $actionID = $availableactions | Where-Object {$_.Title -eq 'Universal EUC Sync'} | Select-object Id
    
    1. Retrieve the action signature
    Get-CUActionSignature -ActionId $actionID.Id
    

    image.png


    Was this article helpful?