Use System Enviornment Variables in HTTP Requests

Is there a way to use a System Environment Variable in an HTTP request, rather than having to pace it in an *.env.json file? For example, I'd like to do something like this:

GET http://httpbin.org/foo
Authorization: {{SYS.ENV.accessToken}}

to access my "accessToken" system environment variable. Is there a way to do this?

0
4 comments

According to the official documentation, there are only three types of variables available:

The variables' values can be any of the following:

Unfortunately, there is no way to use system-wide env variables. I have quickly checked YouTrack for any similar feature requests but was not able to find any, so please feel free to submit your own:

https://youtrack.jetbrains.com/newIssue

0

Thanks uak282006 That's actual the docs for the implementation done via the ticket I opened. It's good to have the link here for when people find this thread via a web search.

Same info will be in the docs of all IDEs that have the HTTP Client. For example for IntelliJ IDEA: https://www.jetbrains.com/help/idea/exploring-http-syntax.html#system-environment-variables  

0

Please sign in to leave a comment.