How to get OAuth2 Access token from Postman

24 views Asked by At

I have some requests to an API using OAuth2 so I config like the picture below.

Here I configured the authentication to be OAuth 2.0 in the collection and all the requests will be able to access the API properly. This works well

enter image description here

Now I need to decode the access token to get some user's information so that I can customize the request. But I don't know how to receive the access token from OAuth2

I found pm.request.auth but seem it doesn't work because the Authentication of the request is inherited from the parent (collection). Same, I see the access token is set in the header but the header is generated by Postman so I can't get it here

enter image description here

Can someone help me on this?

Thanks.

0

There are 0 answers