How do I get an Auth Token using Postman instead of the browser?

I have read through this and I am trying to get a Auth Token for a test user using postman. I create the following GET…

It says it should return with a 302 including the code and that is how I remember it working but I can’t get Postman to show the response url it just says…

Found. Redirecting to /u/login?state=hKFo2SBud1JHN0lETU9ENW9FM0R2WXA4U1JLZ1dQb3RzbWQ3WKFur3VuaXZlcnNhbC1sb2dpbqN0aWTZIEpFZ2doZEY3Y2xEY3hRaFd4UUFnRGM4OEM5SXI3NWUxo2NpZNkgT0NHT2k5eFZNSDlYa3NjV2VpSXlCVFJ2Y3c4cTUxcEI

So I try to use a browser, the browser shows the URL so I can get the code. I can then use the code to get an access token. But once I get the access token and include it in a header like…

Bearer 5J2FYbpYWbh9iixZ-k6PaWOxXm09fasd

It still tries to redirect me to the login. What am I missing?

I can’t get the code from the url using postman
I can get an access token but when I try to use it I get a 403
What is the proper way to do get a token for a test user?

Hi @jgleason

Welcome to the Auth0 Community.

My recommendation for obtaining a token and testing user authentication would be through the Authentication API debugger extension. This method is preferred since you will be able to leverage Auth0’s UI to perform various authentication flows.

However, if you would like to continue your development using Postman, then I recommend that you enable the Password grant in your application settings. This will allow you to exchange a user’s email/password for tokens. Note that you will want to disable the Password grant once you are done with testing.

Please let me know if you have any other questions, I would be happy to help.

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