When using oAuth 2.0 Authorization on a request…
…you can easily access the accessToken from the request via
However, when you use the “inherit auth from parent” as authorization…
I’ve already tried…
… since the oAuth 2.0 authorization is set up in the collection, but also this won´t work.
Similar threads i found to this topic - but no solution to the problem is given:
Reading Authorization header in pre-request script - Help - Postman
Determining auth type in a pre-request script - Help - Postman
- Make the authorization call
- In the Test tab, extract the token and store it as a collection variable.
- At the collection level, in the authorization tab, set the authorization as the collection variable set in the authorization call.
Then all other requests in the collection can inherit from the parent - collection
The huge benefit of using the oAuth 2.0 Authorization Feature of Postman is to switch between multiple sessions via the “Manage Token” dropdown without having to re-login. Also you can make use of the “auto-refreh token” feature that way. By switching between sessions the “tests” tab is not executed.
When setting up a manual authorization request you loose the benefit described above.
So thanks for the hint, but this does not help me that concern.