Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Not able to get all cookie details using Service Callout Response

We have a Resource API where authentication is based on cookie. So we need to call another login endpoint with username and password to get cookie and use that cookie in resource call authentication.

Here is the problem we are facing with above approach:

1. We implemented login call using service call out and response of service call out cookie is not giving all cookies data. It is giving only the first cookie header

2. we want to get second cookie which contains actual cookie used for authentication in subsequent calls.
Any thoughts on how we can get all cookies information in service callout? 

maheshapi052_0-1744245484287.png

The only cookie value i am getting in trace when we use service call out is 

maheshapi052_2-1744245579054.png

Interestingly when we use target endpoint instead of service call out, we are getting all cookies. So the back up plan for us it to use proxy chaining and call the login proxy form resource proxy.

 

 



 

0 1 53
1 REPLY 1

Hi,

I wonder if the logic that is printing the Cookie(s) is printing only the first cookie. Can you share the print logic? There is also mention that making the call as the Target works correctly. How was the Target call confirmed?

Another thought, depending on the system being called and how the call is being made, the system being called may be responding differently. Is the call to the system being made in the JS or as a ServiceCallout (sorry, it's been long enough since I have used the old trace UI that I don't recognize that icon).