Runs a Python script with configurable UI parameters.
This action is similar to the Run Python Script action, but more flexible, especially when used as a preset. Behind the scenes, it also runs a script, but it isn’t directly visible in the workflow editor. Instead, you can configure custom parameters that look just like the ones in the other built-in actions (text boxes, switches, radio buttons...).
The script can then access these parameters (using the workflow.get_parameters() function) to do something with them. This makes the script a lot easier to reuse, because you don’t have to edit the source code to run it with different parameters. It’s also more convenient for scripts that need multiple inputs.
The parameters for this action are completely customizable. To add/edit parameters, tap on the options (▼) button and select “Edit Parameters”.
There are five different types of parameters available:
You can also insert comments in the parameter list – they are shown as static labels.
To access the parameter values from the Python script, you can use the workflow.get_parameters() function. When the script is run, variables in text parameters are already replaced by their actual values.