Variables Dashboard

View and manage all workflow global variables in a dashboard table format

Overview

The node, named "Variables Dashboard," provides a way to view and manage global workflow variables within n8n. It supports three main operations:

  • View All Variables: Displays all current global variables in a table format, including their names, values, and optionally their types.
  • Bulk Set Variables: Allows setting multiple global variables at once by providing a table of variable names, values, and types.
  • Clear All Variables: Removes all global variables after user confirmation.

This node is beneficial for workflows that require centralized management of global state or configuration data accessible across multiple executions or nodes. For example, you can use it to bulk update environment settings, reset all stored variables before a new run, or inspect the current global state for debugging purposes.

Properties

Name Meaning
Variables Table A table where you define multiple variables to set at once. Each variable has:
- Name: The variable's identifier (required).
- Value: The value to store; can be string, number, boolean, object, or array (JSON supported).
- Type: The type of the variable for proper parsing. Options: String, Number, Boolean, Object, Array.
Display Options Collection of options affecting output display:
- Show Variable Types: Whether to include variable types in the output (boolean).
- Format JSON: Whether to pretty-format JSON values for readability (boolean).
- Sort Variables: How to sort variables in the output. Options: Name (A-Z), Name (Z-A), Type, None.
Confirm Clear Confirmation checkbox required to clear all variables (boolean).

Output

The node outputs a single item with a json field whose structure depends on the selected operation:

  • View All Variables:

    {
      "dashboard": "Global Variables",
      "totalVariables": <number>,
      "variables": [
        {
          "name": "<variable name>",
          "value": <variable value, possibly pretty-formatted JSON string>,
          "type": "<variable type>", // included if Show Variable Types is true
          "rawValue": <original variable value>
        },
        ...
      ],
      "variablesSummary": {
        "totalCount": <number>,
        "byType": {
          "<type>": <count>,
          ...
        }
      },
      "lastUpdated": "<ISO timestamp>"
    }
    

    This output provides a snapshot of all global variables, their counts by type, and last update time.

  • Bulk Set Variables:

    {
      "operation": "bulkSet",
      "variablesProcessed": <number>,
      "successCount": <number>,
      "errorCount": <number>,
      "results": [
        {
          "name": "<variable name>",
          "value": <parsed value>,
          "status": "success" | "error",
          "error": "<error message>" // only present if status is error
        },
        ...
      ],
      "timestamp": "<ISO timestamp>"
    }
    

    This output summarizes the result of attempting to set each variable, indicating success or failure per variable.

  • Clear All Variables:

    {
      "operation": "clearAll",
      "clearedVariables": ["<var1>", "<var2>", ...],
      "clearedCount": <number>,
      "timestamp": "<ISO timestamp>",
      "message": "Successfully cleared <number> variables"
    }
    

    Confirms which variables were cleared and how many.

The node does not output binary data.

Dependencies

  • No external services or APIs are required.
  • The node operates on n8n's global static workflow data storage.
  • No special credentials or environment variables are needed.

Troubleshooting

  • Error: "Variable name is required"
    Occurs if a variable entry in the bulk set table lacks a name. Ensure every variable has a non-empty name.

  • Error: "Cannot convert "" to number/boolean"
    Happens when the provided value cannot be parsed into the specified type. Check that values match their declared types (e.g., numbers are numeric strings, booleans are "true"/"false").

  • Error: "Invalid JSON: "
    When a value declared as an object or array is invalid JSON. Verify JSON syntax correctness.

  • Error: "Please confirm that you want to clear all variables by checking the confirmation checkbox"
    When attempting to clear all variables without enabling the confirmation option. Enable the confirmation checkbox to proceed.

  • Sorting or formatting options may affect output readability but do not impact functionality.

Links and References

Discussion