Logging in a separate URL and redirecting to postman

I’m currently automating the 6 API requests in a collection. While doing so, I encountered a problem where I am not sure how to automate that part if we run the entire collection. after hitting the 2nd request and getting the response, next step would be I will be logging into an URL where I need to provide the credentials to login and authorize something . Once I am done with that, it will automatically redirects me to the postman and I will be saving that token as an variable and utilizing in the further requests downstream. So when I am running these as an entire collection, I am stuck after the 2nd requests because now I have to login in an URL. Can you please assist here? Thanks in advance.

You can’t mimic this type of work flow using Postman as you need the browser interaction.

I don’t know your use case, so I don’t know how important it is to test the exact flow you might be using from a web application but usually you are interested in the application you hit after authentication.

So for testing purposes, I can only recommend changing the authentication type to another method that doesn’t require browser interaction. Like client credentials or password. (That’s if you are using OAuth 2.0 for authentication).

You would need to test the proper flow manually at some point.

Thanks for the explanation @michaelderekjones

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.