Runner specific variables

There are several variable scopes in Postman. But they are all somehow permanent from view of running requests. If I start a runner to perform some requests there is no possibility to specify or override variable values only for the lifetime of this tests. I have to change either global or environment or collection or local or interaction variables and have to save the global, environment or collection scope or test-script or data file. So the changes are permanent and I have to remember to remove or change back the variable after my test run and if I don’t future test runs will behave different without my awareness.

So I would appreciate a new runner variable scope. Variables of this scope can be specified (or imported from file) within a runners window. These variables exist only for the lifetime of this runner instance and overrides other variables from global, environment and collection scopes when accessed in the request builder via double brace replacement.

This would allow to temporary adjust some settings during a test run without the need to save and withdraw these changes to permanent storage. Or without the need to hold a confusing number of environments to address all issues.

Hi @reinerben,
There’s a button in the runner that you can make use of before running your collection / folder, which says ‘Persist Variables’ (In older version) or ‘Keep variable values’ (In the latest version of the Postman Native App)

Every run that is ran by the runner, is ran in a sandboxed environment.
So, all the variables being worked upon during the run stay inside the sandbox.

If this is turned off (unchecked) then after the run has finished executing (completely stopped), then variables are not persisted throughout the app’s ecosystem, they are simply discarded.

Incase, this option is turned ON (checked) then after the run, all the variable modifications that happened get persisted throughout the app and that’s why you can see those change being reflected in the requester itself.

For every run that you’ll make, you can toggle this setting as per your need.

I think this will help you.

Hi sicvan,

Unfortunately this does not help in my situation. I know, there is the checkbox ‘Keep variable values’.
But what I would need is a way to add (or override) variables here in the runners window which then will be discarded (or kept if checkbox is activated) when the runner exits.

The only way I know to change variable values is in the collection or request scripts. But since these scripts are also saved somewhere in postman’s storage this doesn’t help me because the same changes are made at every runner process (when the script runs) not only for one runner instance.

What I want is to specify a variable value which is only known for one runner lifetime without the need to temporary change and save a script, an environment value, a global value or a data file.