SOAP Request

Is it possible to Pass through the SOAP request in APIGEE. As per my understanding anything which is coming to inside APIGEE it will convert it to JSON or XML {JSON TO XML policy } , BUT I am not sure how to pass through the SOAP as it is .
Please do suggest what can be done in this .?????

Solved Solved
0 8 2,147
1 ACCEPTED SOLUTION

Yes, Apigee will take a any incoming SOAP request and pass it to your target system. Only if you use some on the mediation policies available the reuqtes will be transformed in JSON or XML.

http://docs.apigee.com/apigee/mediation-policies

View solution in original post

8 REPLIES 8

Yes, Apigee will take a any incoming SOAP request and pass it to your target system. Only if you use some on the mediation policies available the reuqtes will be transformed in JSON or XML.

http://docs.apigee.com/apigee/mediation-policies

@Miren thanks for the quick response .

I tried this , i use Weather WSDL soap from apigee with "PASS THROUGH" and i did not use any mediation-policies , but now i am getting XML .

Still not getting SOAP ,
Please help .

@Ankit Dwivedi ,

Yes, Absolutely you can do that. You can create PassThrough SOAP request. Infact Apigee API Proxy wizard SOAP sample demonstrates same. It's not true that anything coming into APIGEE will be converted into JSON or XML.

For your understanding , I have created simple passthorugh SOAP proxy in Apigee for weather WSDL mentioned here.

Please find apiProxy bundle globalweather-rev1-2016-09-06.zip

Sample CURL call below that demonstrates Passthrough SOAP in Apigee, I have deployed above api proxy in my org,

curl -X POST -H "SOAPAction: http://www.webserviceX.NET/GetCitiesByCountry" -H "Content-Type: text/xml;charset=UTF-8" -H "Cache-Control: no-cache" -H "Postman-Token: fe6ec586-260f-764c-4708-8193a5092d95" -d '<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <GetCitiesByCountry xmlns="http://www.webserviceX.NET">
      <CountryName>India</CountryName>
    </GetCitiesByCountry>
  </soap:Body>
</soap:Envelope>' "http://anildevportal-test.apigee.net/globalweather"

Hope it helps.

@Anil Sagar

thanks for your response .

I tried the same bundle in my free org . i don't have curl so i post the same request through API CONSOLE .
But in response i am XMl , It is not the same SOAP with {envelop and body which we see in SOAP request }.
My only concern is i need to passthrough soap with "post request" , in response i should get SOAP , while doing it is converting into XML (in response i am geting XML) is that fine or apigee should receive SOAP instead of XML in response.

I am attaching the screen shoot of the my Request .

Please have a look at this.

3493-apigee.png

Former Community Member
Not applicable

@Ankit Dwivedi

I recommend that you use the wizard to generate the proxy. Steps:

1) Select "+ API Proxy"

2) Select SOAP Service

3) Click on "Example URL", select the Weather WSDL.

4) Click on "Validate" and Click "Next"

5) API Proxy Type -> Select "Pass- Through SOAP"

6) Accept defaults for the remaining screen and deploy it.

@Srinandan Sridhar ,

Ya i did the same , but the thing is I need SOAP in response not xml ...

Hi @Ankit Dwivedi, I am not sure if you are doing it right, if you are creating a SOAP passthrough, the proxy does not expect any pathsuffix. It does the routing based on 'operation' present in SOAP request payload that we send in the request . This is as per the code present in the proxy. As it is a simple pass-through, no header is added by apigee and the Content-Type that we are getting in response is returned by the backend system.

I have tested the same and it is working fine.