Global Variable Support

The idea is:

To create a resource for global variables with various scopes. 1. Scoped to the workflow, and 2. Scoped to the Execution, 3 Scoped to the User.

it could be access similar to the way we use Luxon. allowing you to instantly … do something like merge “number of monkeys today = {{$var.variableName}}” into a report.

My use case:

Managing a counter is a really usefull programming concept, weather it is how many times an error occurred, how many times a loop ran, etc. And inside N8N it is very difficult to establish said loops because I cannot declare easily accessible variables.

Of course there are many workarounds… but it is generally darn annoying.

ESPECIALLY when I want one workflow to know something about another one.

I think it would be beneficial to add this because:

It would enhance the capability of the platform in many ways.

Are you willing to work on this?

Implementation of this would be way over my head.

Hi @roofboard

There are variables that can be used within a workflow. They are linked to the workflow itself, so sadly not global for use in other workflows. But that can easily be done with some kind of external spreadsheet or whatever you prefer.
They are mentioned here: Function Item - n8n Documentation

Hope this helps you for now.

Ps. Dont forget to vote.

I think a key value store would address your issue. This has been requested before, make sure you pop a vote on it so it gets more traction:

1 Like