Configure the output response REST endpoint

javeriaarif705_
Tera Contributor

Hi all. 

I have followed every step from the documentation to configure the output response endpoint, but when I try to run the API from the postman or even the ServiceNow "try" functionality I get the following message popped up:

"You are not logged in, or your session has expired. Redirecting to the login page".

Although, the status code received on postman is "200", which means the api hit is successfult, but I am not getting a json output response which is expected.

 

Also, my ServiceNow bot is standalone. I want to send a json request via postman and get a json response on postman.

1 REPLY 1

cloudops
Tera Expert


This issue might be due to several reasons. Here are some troubleshooting steps:

1. Check Session Timeout: Ensure that your session has not timed out. ServiceNow sessions expire after a certain period of inactivity. If your session has expired, you will need to log in again.

2. Verify API Endpoint: Make sure that the API endpoint you are using is correct. A wrong endpoint can lead to such issues.

3. Check User Credentials: Ensure that you are using the correct user credentials. If you are using incorrect credentials, you will not be able to log in.

4. Use Basic Authentication: If you are using Postman, try using Basic Authentication. Enter your ServiceNow instance's username and password in the authorization tab.

5. Enable CORS: If you are making a cross-origin request, you might need to enable CORS (Cross-Origin Resource Sharing) in your ServiceNow instance.

6. Check Web Service Role: The user account should have the "web_service_admin" role to access the API.

7. Use API Explorer: ServiceNow provides an API Explorer where you can test your API calls. Try using this to see if you get the same error.

8. Check for IP Restrictions: Your ServiceNow instance might have IP restrictions that prevent you from accessing the API from certain IP addresses.

9. Use a REST Client: If you are still having issues, try using a REST client like Postman or Insomnia. These tools can help you debug your API calls.

10. Contact ServiceNow Support: If none of the above steps work, you might need to contact ServiceNow support for further assistance.

 

For asking ServiceNow-related questions try this :
For a better and more optimistic result, please visit this website. It uses a Chat Generative Pre-Trained Transformer ( GPT ) technology for solving ServiceNow-related issues.
Link - nowgpt.ai