Plugins Called in a Script¶
Calling a plugin from a script is one of two methods for using a plugin, the other being adding a plugin to an activity. The plugin must be one that is specifically intended to be executed within a script, such as the Jitterbit HMAC-SHA256 Generator plugin.
Initializing Global Variables¶
Many plugins require global variables to be initialized prior to executing the plugin. For information on determining whether these values are required, as well as how to set required or optional values, refer to Global Variable Initialization.
Executing a Plugin from a Script¶
The Plugins tab of the component palette provides a list of plugins that can be run inside a script:
In order for plugins to appear within Cloud Studio, they must be installed on the agent:
- Cloud Agents: If you are using the Cloud Agent Group, a range of Jitterbit-provided plugins is already installed.
- Private Agents: If you are using a Private Agent Group, see Customizations > Plug-ins for instructions on adding plugins.
For a description of each Jitterbit-provided plugin, see Plugins Available in Jitterbit Harmony.
Within a script, you can use a plugin as an argument for the
RunPlugin function by inserting the plugin reference path.
To add a plugin reference path to a script (Jitterbit Script only), use one of these methods:
- Drag the plugin from the palette to the script to insert both the
RunPluginfunction and the plugin reference.
- Double-click the plugin in the palette to insert the plugin reference at your cursor's location within the script.
- Begin typing the plugin name and then press
Control+Spaceto display a list of autocomplete suggestions. Select a plugin to insert the plugin reference.
- Manually enter the plugin reference.