Use Authentication (different Token) from Collection within Requests in Postman

Viewed 137

I try to create a postman collection for my backend service which uses Azure B2C Authentication.

Within my Collection I added Authentication, which works and I can authenticate within my Chrome Browser: enter image description here

Once I am authenticated and redirected back to Postman it says that an access_token can not be found. I can see that it is in id_token: enter image description here

Now I created also a Request with Authentication Type oAuth 2.0 where I could select Available Token. But as the token is not within access_token it does not autofill the token. Is there any way to tell Postman that i want to use id_token as access_token within my requests in the collection?

Thanks for your help and feedback

enter image description here

1 Answers

As you saved your token with the name as Azure AD B2C Authentication, for your requests, you can select the Azure AD B2C Authentication from your available tokens.

This will auto-fill the token

I created the token with name as access token

enter image description here

Now for my request, I selected the access token from the available tokens under Access Token

enter image description here

Then the token is auto-filled as below

enter image description here

In this way, you can use the Access Token in collections in postman

Related