from orionclient.session import APISession
from orionclient.types import WorkFloeSpec
from orionclient.helpers.parameterize import parameterize_workfloe

# Get a WorkFloe specification by ID
workfloe = APISession.get_resource(WorkFloeSpec, 999)

# Define the values every floe will have
defaults = {"promoted": {"in": 618}}
parameters = []
# For each iteration run the dummy cube with the parameter step as the iteration number.
for x in range(5):
    parameters.append({"cube": {"dummy": {"step": x}}})
# Returns a list of WorkFloeJob objects
jobs = parameterize_workfloe(
    workfloe, "Example Parameterized Floe", defaults, parameters
)
