SRXEnv

1.0.1

Provides the ScriptRunner PowerShell Host Environment Variable $SRXEnv for test and developement purposes.

The SRXEnv hashtable provides the following keys:

[string]ReportEmail:
If you have an SMTP server available, the ScriptRunner service can send you email notifications containing execution reports, on error or on success.
Recipient email address (comma sep
Provides the ScriptRunner PowerShell Host Environment Variable $SRXEnv for test and developement purposes.

The SRXEnv hashtable provides the following keys:

[string]ReportEmail:
If you have an SMTP server available, the ScriptRunner service can send you email notifications containing execution reports, on error or on success.
Recipient email address (comma separated list). The full action report will be sent to this address.

[string]ResultEmail:
Recipient email addresses (comma separated list). Only the ResultMessage will be sent to this address.

[ArrayList]ResultList:
A scripted query must specify this list of string values. The list is associated with the corresponding action parameter.

[ArrayList]ResultList2:
A scripted query can specify this optional list of display names. The list appears as drop-down list for the associated action parameter.

[string]ResultMessage:
This message will show in the reports, and in the immediate result window of the Delegate and Self-Service App.

[string]ResultObjectJSON:
The script can now provide (simple) structured result data by writing a (small) JSON string to $SRXEnv.ResultObjectJSON.
ScriptRunner will provide this JSON string in the OutSerializedPSObjects report field, for post-processing by the caller of the Web Service Connector.

[DateTime]SRXStarted:
The timestamp of the start of the script execution. (readonly)

[string]SRXStartedBy:
The user account that requested the execution of the script. (readonly)

[string]SRXStartedIP:
IP address of the client that sent the request to perform the script execution. (readonly)

[string]SRXStartedVia:
Name of the application that started the execution of the script. (readonly)

Minimum PowerShell version

3.0

Installation Options

Copy and Paste the following command to install this package using PowerShellGet More Info

Install-Module -Name SRXEnv -RequiredVersion 1.0.1

You can deploy this package directly to Azure Automation. Note that deploying packages with dependencies will deploy all the dependencies to Azure Automation. Learn More

Manually download the .nupkg file to your system's default download location. Note that the file won't be unpacked, and won't include any dependencies. Learn More

Author(s)

ScriptRunner

Copyright

(c) 2019 ScriptRunner Software GmbH. All rights reserved.

Owners

Tags

ScriptRunner Windows Linux MacOS

Functions

Reset-SRXEnvironment

PSEditions

Desktop Core

Dependencies

This module has no dependencies.

Version History

Version Downloads Last updated
1.0.4 103 3/18/2021
1.0.3 139 2/11/2020
1.0.2 107 8/14/2019
1.0.1 (current version) 42 7/18/2019