Author Message
WilsonYu
Joined: Nov 6, 2013
Messages: 3950
Offline
Yes, it will be in the next release.
RajatVerma
Joined: Mar 5, 2014
Messages: 101
Offline
Hi Wilson,

Any idea on how to retrieve the message body(response message) as well. for example I am getting backend response as 404 and message response as

{
"responseCode": "2",
"responseDescription": "This number doesn't exist"
}

I have validated this in postman but in OD I am not able to get such response using ddlastException variable. I have tried all options but not found anything useful. ddlastException.message only returns "404 Error: Not Found".

Actually I need to provide different behaviors in case of response code 2, 3 etc.

Thanks,
Rajat Verma
WilsonYu
Joined: Nov 6, 2013
Messages: 3950
Offline
It's hidden inside the Axis2 client implementation.
You would have to do what DanielStingl mentioned earlier in this thread using httpclient with which I believe no additional dependency is required.
Go to:   
Mobile view