About variables in Automator on Mac
A variable is a named container that is used to temporarily store information to use when needed. Variables can contain all types of data, such as text, a reference to a file or a list of object references. You can refer to the same variable from action to action or workflow to workflow, although the information within it may be different. For example, the date may change, although the variable Today’s Date remains the same.
You can add a variable to an action or to a workflow.
Some variables in Automator are constant values — for example, “Today’s date” or “My name”. Automator temporarily holds a value while a workflow runs.
Some actions may allow you to choose a declared variable from a pop-up menu. Other actions give you the option to create a new variable from a pop-up menu.
For more information about adding variables to an action, see Add variables to an action.
For more information about adding variables to a workflow, see Add variables to a workflow.