How to keep connect alive until the final API

snowsnow367
Tera Contributor

Hi Community,

We are doing REST API integration with BeyondTrust, and I need to call multiple APIs, as shown in the screenshot, in order.

First, we need to call the Login API, next getaccount, and the remaining APIs. For login, it's successful, and the rest of the APIs are showing "user not authenticated". But it's working as expected when we tried it from Postman. 

APIsAPIs

 

How can we keep the connection alive till the end?

 

 

Thanks,
Mahender

 

 

 

8 REPLIES 8

Ankur Bawiskar
Tera Patron

@snowsnow367 

did you check with the 3rd party team if this is allowed and how it can be done?

better to check with them

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar ,  yes. It's allowed.

 

Thanks,
Mahender.

@snowsnow367 

we are not sure how that 3rd party API works, did you check with the team how it can be done?

Any documentation from them?

may be for each API endpoint they want authentication again

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

Laveena-Agarwal
Mega Sage

Hi @snowsnow367 

 

This appears to be a credential-related issue, where the user is unable to log in to ServiceNow.

For testing purposes, when you hit the login API, you will receive a token (or key). This token needs to be included in the HTTP headers of all subsequent REST methods of outbound REST message