Config var in workflow definition?

Hello! I have an orquestra workflow which has a task at the end to send out a message to chat room . . . I would like to make this message conditional on a flag set in config, so I guess I would do something like

task_before_sending_out_message:
    action: ex_pack.poopy
    next:
        - when: <% succeeded() %> and <% ***config.flag == True*** %>
          do: task_to_send_out_message

task_to_send_out_message:
    action: gchat.send_message "yay"

What do I need to put for “config.flag” to be able to use a var from the pack config?

Thanks!!!

@guymatz you can access context variables with ctx().var_name. They need to be set in the vars array at the beginning of the workflow. Then you publish it to the context.

Some posts here: Passing output to slack from workflow

Check out vars here: Orquesta Workflow Definition — StackStorm 3.1.0 documentation

You can see them on the second link getting assigned, published and printed.