thunder-client-support icon indicating copy to clipboard operation
thunder-client-support copied to clipboard

Authentication details on Environment

Open bensonrlee opened this issue 2 years ago • 2 comments

Please describe feature/problem details and the solution you'd like. Right now, authentication details (username and password, etc), can be linked at the collection level. Is it possible to link authentication details based on the environment.

For example, I can have same API endpoints (except for base URL) on dev and prod, but the credentials in dev and prod would not be the same.

Describe alternatives you've considered

  1. Update the authentication details depending on the environment being tested.
  2. Duplicate the collection and link the second collection to the second environment.

bensonrlee avatar Sep 28 '23 17:09 bensonrlee

Hi @bensonrlee

You can use env variables in authentication fields, e.g {{username}} and {{password}}

and use different values in Staging, and production environments. When you change the active environment, it will change values accordingly.

rangav avatar Oct 08 '23 06:10 rangav

Hi Is it possible to change from Basic to OAuth depending on the evironment?

metamoof avatar Jan 05 '24 12:01 metamoof