environment varialbels not working in postman code example
Example 1: accesing variables in api
You can use double curly braces to reference variables
throughout the Postman user interface. For example,
to reference a variable named "username" in your request
settings, you could use the following syntax with
double curly braces around the name:
{{username}}
Example 2: defining collection variables
Use pm.collectionVariables to define a collection variable:
pm.collectionVariables.set("variable_key", "variable_value");