Parameter
class Parameter
An interface for working with workflow parameters on Redivis. Parameters are used to store sets of values that can be referenced across transforms and notebooks in a workflow.
Constructors
redivis.parameter(reference)
Create a reference to a parameter based on its (qualified) name
workflow.parameter(reference)
Reference a parameter within a specific workflow.
Returns a list of Parameters within a workflow
Examples
import redivis
workflow = redivis.workflow("username.workflow_name")
parameter = workflow.parameter("my_param").create(values=["foo","bar"])
print(parameter.get_values()) # ["foo", "bar"]
parameter.update(values=["hello","world"])
print(parameter.get_values()) # ["hello", "world"]Attributes
workflow
A reference to the Workflow instance that is associated with this parameter.
properties
A dict containing the API resource representation of the parameter. This will only be populated after certain methods are called, particularly the get method, and will otherwise be None.
qualified_reference
The fully qualified reference to this parameter
For example,
imathews.example_workflow_climate_analysis:x7kh.my_param:27sascoped_reference
The canonical reference for the parameter, without any qualifiers. E.g., my_param:27sa
Methods
parameter.create(*, values, type)
Create a new parameter within a workflow
parameter.delete(*, values, type)
Delete a parameter
Fetches the parameter, after which parameter.properties will contain a dict with entries corresponding to the properties on the parameter resource definition. Will raise an error if the parameter does not exist.
Fetches the list of values associated with the parameter.
Check whether the parameter exists.
parameter.update([*, name, values, type])
Update the parameter's name, values, and/or type.
Last updated
Was this helpful?