Get access denied error when requesting OAuth Access Token

funkeke
Kilo Sage

I am using Postman to test getting an OAuth access token. I am able to get the access token successfully from my personal dev instance, but not from my employer's dev instance. I am using the password grant type, and from what I can tell the request is formed correctly (I've read a lot of articles here in the community). But I am still getting access denied.

I am doing a POST with parameters included in the body. It is set to x-www-form-urlencoded and Authorization is set to no auth. The only header included is content-type. I know the account being used is active and the password is correct. The account just has basic permissions (it's not an admin), since I don't THINK any special roles are required to make an access token request.

find_real_file.png

As mentioned, I am able to make the exact same type of request to my personal instance just fine. I feel like there is some configuration set up in my company's instance that is blocking this request. We do have SSO, but I'm not sure if that could affect it. Any ideas or things I can try to debug? Are there any logs I can access to find out more details on the access denied message?

1 ACCEPTED SOLUTION

Tony Chatfield1
Kilo Patron

Running a quick test I get the same error if any of the fields you have mapped with postman environmental parameter values are incorrect.

Maybe you could start by hard coding the values to ensure they are right,
then once you have it working move them to postman environmental variables.

 

View solution in original post

2 REPLIES 2

Tony Chatfield1
Kilo Patron

Running a quick test I get the same error if any of the fields you have mapped with postman environmental parameter values are incorrect.

Maybe you could start by hard coding the values to ensure they are right,
then once you have it working move them to postman environmental variables.

 

Goodness, somehow my environmental variable for client ID was missing the first letter, must have been a miss-copy. Good call on double-checking those--using the environmental variables is best practice when working collaboratively, but it makes it harder to double-check your values!

It is working now 🙂