Skip to Content

Capturing HTTP Response Codes for WebService call

Hi Experts,

Is there a way to capture SAOP webservice HTTP response code(like 200,401,500 etc..), here the SAOP webservice is at the receiver side and based on the response code we have multiple operations to carry.

Can you please help on how to capture the HTTP response code for a web service call.

Thanks in advance..

Sarat.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Nov 03, 2016 at 09:05 AM

    Hello Sarat,

    PI will treat any non HTTP 2XX return code as an Error Code and will make your PI Message fail.

    Hence, if you get HTTP 401 - Unauthorized or HTTP 403 - Forbidden, your PI Message will go into error. Likewise if you get HTTP 500 - Internal Server Error, the message will go into error.

    HTTP 200 is typically the Header code to return that the HTTP Call was successful and hence HTTP 200 is treated as a successful call by your SOAP Adapter.

    The question is - why do you want to look at the header codes as this is implicitly taken care by PI. What is the end objective here or what are you trying to achieve?

    Regards,

    Bhavesh

    Add comment
    10|10000 characters needed characters exceeded