# Variables

## Introduction

The 'Variables' feature in Autom Mate provides users with a powerful tool for **storing**, **manipulating**, and **transferring data** within processes. It serves as a temporary storage unit during the execution of actions, enabling dynamic data handling.

The primary purpose of variables is to enhance workflow **efficiency** by enabling users to work with **different data types**, **perform calculations**, and **store temporary results**. They facilitate seamless interaction between various actions within a flow.

{% embed url="<https://youtu.be/FwBI5ntUqbA>" %}

***

## What are Variables?

Variables in Autom Mate act as placeholders for storing and processing data. They provide flexibility in working with different types of data and enable users to create dynamic processes.

{% hint style="info" %}

### Key Features

* **Array**: Store sequential elements of the same type.
* **Boolean**: Represent true or false values.
* **Data Table**: Store data in a tabular format.
* **Date**: Store date values.
* **Dictionary**: Use key-value pairs for data storage.
* **Number**: Handle numeric values for calculations.
* **Object**: Refer to addresses of objects.
* **String**: Store sequences of characters or text.
  {% endhint %}

***

## How To Use Features

### Creating a Variable

Creating a variable allows users to define a storage space for data within the flow.

#### **Usage**

{% stepper %}
{% step %}
**Open the variable section in the flow.**
{% endstep %}

{% step %}
**Click on "Add New Variable."**

**Variable Types**

* **Array**: Store sequential elements of the same type.
* **Boolean**: Represent true or false values.
* **Data Table**: Store data in a tabular format.
* **Date**: Store date values.
* **Dictionary**: Use key-value pairs for data storage.
* **Number**: Handle numeric values for calculations.
* **Object**: Refer to addresses of objects.
* **String**: Store sequences of characters or text.
  {% endstep %}

{% step %}
**Select the Variable Type.**
{% endstep %}

{% step %}
**Fill in the details**

* **Name**
* **Description**
* **Input, Output, Customizable options**
  {% endstep %}

{% step %}
**Click "Save."**
{% endstep %}
{% endstepper %}

<figure><img src="https://4222414448-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FMAf5diEa8kgXDA6h47Cu%2Fuploads%2FZo03OWAYvVe5QWs6fyiQ%2Fvariables.gif?alt=media&#x26;token=c6e733b3-7dd7-495d-9419-f47368bc0c26" alt=""><figcaption></figcaption></figure>

***

### Using Variables in Actions

Utilize variables within actions to process, manipulate, or display data.

#### **Usage**

{% stepper %}
{% step %}
**Enclose variable names between ## symbols.**

Example: **##User\_Info##**
{% endstep %}

{% step %}
**Access specific values inside data tables using indexes.**

Example: **##Sales\_Data\[Product]##**
{% endstep %}
{% endstepper %}

***

## Best Practices

Follow best practices for variable naming, data integrity, and clear documentation.

#### **Usage**

{% stepper %}
{% step %}
**Variable Naming**

* Use descriptive names.
* Follow a consistent naming convention.
  {% endstep %}

{% step %}
**Data Integrity**

* Validate input data.
* Ensure correct variable updates.
  {% endstep %}

{% step %}
**Clear Documentation**

* Document variable purpose and usage.
  {% endstep %}
  {% endstepper %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.autommate.com/userguide/autom-features/variables.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
