Skip to main content

Introduction

Variables allow you to store important pieces of information in a single place. If the information changes, you only need to update the variable once, rather than in multiple CloudFlows, reducing errors and making flows easier to maintain. In addition, variables help to make your CloudFlows more reusable. Instead of hardcoding values, you can use the same CloudFlow for different projects or accounts.

For example, you can create an approver variable that can be used in all flows requiring action approval. You only need to update the approver's email address once by amending the approver variable, rather than updating each individual flow.

You can reference variables in your CloudFlows in the same way you reference data.

Variable scope

Variables can be global or local.

  • Global variables are accessible to all the CloudFlows within your organization. You can use global variables when you have data that needs to be accessed by more than one CloudFlow. In other words, the data is a constant that should be centrally managed.

  • Local variables are accessible within the CloudFlow where they are defined. You can use local variables when data is only relevant to a specific CloudFlow. For example, if you have a CloudFlow specific to a particular account, you can use a local variable for the account ID. This means you only need to define the ID once, rather than adding it to each node in the flow. If you want to reuse the CloudFlow for another account, duplicate the flow and update the account ID variable, saving time and making your CloudFlows more flexible and easier to maintain.