Hi @AmritRaj
The http response code you get is 403 == Authorization Overreach. The typical reason for this error is that the client credentials are insufficient for the api request. Either you are going to an endpoint for which these credentials are not allowed OR the URL destination is incorrect.
In my Postman configuration, I save the clientId and clientSecret in the environment variables, let the Pre-request script of each collection create/reference the accessToken (variable also in the env vars), and set the Authorization of each collection to grab the {{accessToken}} variable. Then, each api call Authorization is set to “inherit auth from parent”.
I am unable to duplicate the experience you have. Here’s what I did:
1. In IdentityNow, Log in as a top level admin, generate a new PAT, then insert the new clientId and clientSecret into the Postman environment vars.
RESULTS: I can successfully retrieve data from both v3 and beta collections: 200 OK
2. Still as Admin, register a new API client, client credentials grant type, and get a new clientId and Secret.
3. In the Postman environment vars, simply replace the clientId and clientSecret values with the new client credentials API management client credentials. No other changes made.
4. Test “get Accounts” API call from both v3 and beta colections
RESULTS: Both of these still work.
5. Test /v3/public-identities and beta/identities
RESULTS: Both of these ALSO work.
Suggestions:
1. Test v3/public-identities. Do not make any other changes. Does this work?
EXPLANATION: If YES, it does work, then the client credentials you generated do NOT have the proper rights OR scope. A End User can access public-identities but not do anything else.
SOLUTION: Log in as Org Admin, generate a NEW client credentials clientId and clientSecret.
2. Look at the client Id and Secret that you copied. Do you have any spaces or carriage returns in ANY of the values you saved in the beta API call? Spaces and carriage return in either value field in Postman will nullify/break credentials.
3. Look at the Postman console. Expand the request body. Look for the exact reason that it failed. Look at the URL - is this correct. Is the client id or client secret set to “”? If so, then something is wrong with the values you copied OR the auth they had when you generated them (not an admin user at the time of generating them, for example).
4. Study the v3 and beta api calls: one that is successful and 1 that fails with 403 error. What is different. Study and compare every field, every value, every string, every setting, the top of each collection Authorization page. Something is different.
5. Change your Postman config. If you are using the SailPoint Postman workspace collections:
a.) Add the clientId and clientSecret to the environment variables (exactly like that).
b.) at the top of each collection, ensure that the Authorization is set to “Bearer Token” Value == {{accessToken}}.
c.) ensure that the api request auth is set to “inherit auth from parent” and try sending again. What error do you get?
Because there are various ways to configure Postman, troubleshooting your exact config is challenging in this context and venue. I recommend to focus on the error, what 403 means, and review the Postman console and every setting to find the difference. Look for spaces or carriage returns in any of the client id and secret fields within Postman - those will break an api request. I hope these suggestions lead you to the answer in your config. Something must be different between the 2 collections or api requests.