Receiving 200 status but no value in Response. Tried the OnAfterResponse and this is the result (please see image), another weird thing is when I tried it in Postman, I receive 200 status and the response is complete.Anyone here encounter same as this issue, if you have an idea how to resolve it.
The datatype of the response is List
Hello
Here we have the same similar issue, you can refer to this post, hope this will help you -
ThanksTousif Khan
Tried adding header AcceptEncoding: "*". Still the same.
Hello RD,
Can you please share the OML for the same?
Hi RD,
If the status is 200, but you don't seem to receive a response, you either have specified the wrong structures, or the API doesn't send anything. In general, please do not use OnAfterResponse to check this, but increase the log level of your API and check in Service Center what was actually sent.
In this case, the ResponseText is "[]", so the API sends an empty array, which explains why you didn't see anything.
Tried the logging set to full, and this one is the result. I still cant see why the response is like [].
You can't see it, because that's what the remote service does. Apparently, you send something that leads it to conclude it doesn't have data for you, so it sends an empty array.
I'd study the API's documentation thoroughly, and start with a very simple use case, in Postman rather than OutSystems so it's easier to fiddle with parameters.
Weird part is that, I tried it in postman and its response is not empty.
Then compare what Postman sends with the integration logging in Service Center. It not only logs what is returned, but also exactly what you sent.
Hello Kilian!Checked in headers passed in postman and OS, there is a difference in 'X-Global-Transaction-ID' . Can it be the cause?
Postman
OS
I would sincerily doubt that. It's an X-header, so likely ignored by the receiving party.
Hello RD.,
As per my understanding i think do check the parameters and headers which you are passing in the API. Also check the output structure .
Hope this will help you.
Regards