Invoke-PSUCommand
Sends events to an event hub.
Synopsis
Syntax
Invoke-PSUCommand [-AppToken <String>] [-ComputerName <String>] [-Data <Object>] -Hub <String> [-Integrated] [-UseDefaultCredentials] [-ConnectionId <String>] [-Credential <PSCredential>] [-TrustCertificate] [-Timeout <Int32>] [<CommonParameters>]
Invoke-PSUCommand [-AppToken <String>] [-ComputerName <String>] [-Data <Object>] [-Integrated] [-UseDefaultCredentials] -Computer <String> [-Credential <PSCredential>] [-TrustCertificate] [-Timeout <Int32>] [<CommonParameters>]
Invoke-PSUCommand [-AppToken <String>] [-ComputerName <String>] -Hub <String> [-Integrated] [-UseDefaultCredentials] [-ConnectionId <String>] [-Command <String>] [-Credential <PSCredential>] [-Parameters <Hashtable>] [-TrustCertificate] [-Timeout <Int32>] [<CommonParameters>]
Invoke-PSUCommand [-AppToken <String>] [-ComputerName <String>] [-Integrated] [-UseDefaultCredentials] [-Command <String>] -Computer <String> [-Credential <PSCredential>] [-Parameters <Hashtable>] [-TrustCertificate] [-Timeout <Int32>] [<CommonParameters>]Description
Parameters
-AppToken
-ComputerName
-Data The data to send to the client. This data will be serialized to CliXml and deserialized on the client.Required? falsePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false-HubThe name of the event hub to send the event to.Required? truePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false -Integrated [<SwitchParameter>] Not used.Required? falsePosition? namedDefault value FalseAccept pipeline input? FalseAliases noneAccept wildcard characters? false -UseDefaultCredentials [<SwitchParameter>] Not used.Required? falsePosition? namedDefault value FalseAccept pipeline input? FalseAliases noneAccept wildcard characters? false-ConnectionIdThe connection ID to send the event to. If not specified, the event will be sent to all connected clients.Required? falsePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false-CommandThe command to run on the agent.Required? falsePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false-ComputerThe computer to run this command on.Required? truePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false-CredentialCredentials to login to the PowerShell Universal Management API.Required? falsePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false-ParametersA hashtable of parameters to send to the command.Required? falsePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept wildcard characters? false -TrustCertificate [<SwitchParameter>] Whether the cmdlet should ignore certificate issues.Required? falsePosition? namedDefault value FalseAccept pipeline input? FalseAliases noneAccept wildcard characters? false-TimeoutThe timeout in seconds for the command to run.Required? falsePosition? namedDefault value NoneAccept pipeline input? FalseAliases noneAccept 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).InputsNoneOutputsSystem.ObjectNotes-------------------------- Example 1 --------------------------PS C:\> Invoke-PSUCommand -Hub 'MyHub' -Data @{ Name = 'Adam' }Sends an event to the MyHub event hub. All connected clients will receive the event.
Last updated
Was this helpful?