Get-SmaJobOutput

Gets the output of a SMA job.

Syntax

Get-SmaJobOutput
   -Id <String>
   [-StartTime <DateTime>]
   -WebServiceEndpoint <String>
   [-Port <Int32>]
   [-AuthenticationType <String>]
   [-Credential <PSCredential>]
   -Stream <String>
   [<CommonParameters>]

Description

The Get-SmaJobOutput cmdlet gets the output of a Service Management Automation (SMA) job. Specify an SMA job ID and the web service endpoint.

Examples

Example 1: Get the output of a Service Management Automation job

PS C:\> Get-SmaJobOutput -Id "2989b069-24fe-40b9-b3bd-cb7e5eac4b64" -WebServiceEndpoint "https://contoso.com/app01"

This command gets all of the output of the job with the specified GUID for the specified web service endpoint.

Parameters

-AuthenticationType

Specifies the authentication type. Valid values are:

  • Basic
  • Windows

The default value is Windows. If you use Basic authentication, you must provide credentials by using the Credential parameter.

Type:String
Accepted values:Basic, Windows
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Credential

Specifies a PSCredential object for the connection to the SMA web service. To obtain a credential object, use the Get-Credential cmdlet. For more information, type Get-Help Get-Credential.

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

-Id

Specifies the job ID, as a string.

Type:String
Aliases:JobId
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Port

Specifies the port number of the SMA web service.

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

-StartTime

Specifies a start time as a DateTime object. The cmdlet gets output created after this time. To get a DateTime object, use the Get-Date cmdlet.

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

-Stream

Specifies the type of output. Valid values are:

-- Any -Debug

  • Error
  • Output
  • Progress
  • Verbose
  • Warning

Note: Stream values are case-sensitive. If the wrong case is used, the error "job id '<GUID>' not found" is returned.

Type:String
Aliases:OutputType
Accepted values:Any, Progress, Output, Warning, Error, Debug, Verbose
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-WebServiceEndpoint

Specifies the endpoint, as a URL, of the SMA web service. You must include the protocol, for example, http:// or https://.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False