1

How can a SOAP API be proxied using WSO2 Microgateway? Is there any example / documentation that explains the steps.

I am also interested on how will the interceptors work in case of soap request and response.

1 Answers1

2

Creating soap API can be done in APIM[1] and import it to microgateway using the import command[2].

Once the API is imported the swagger file will be added in the gen/api_definitions folder of your project. Then refer the message transformation[3] in order to add interceptors. You can define the interceptor name in the generated swagger file using x-wso2-request-interceptor and x-wso2-response-interceptor swagger extensions

[1] - https://docs.wso2.com/display/AM210/Create+and+Publish+a+SOAP+API
[2] - micro-gw import -a <API_NAME> -v <API_VERSION> <PROJECT_NAME>
[3] - https://docs.wso2.com/display/MG310/Message+Transformation
  • Thanks! Can we mix both REST and SOAP APIs in a single microgateway? We are using openAPI specification for the REST APIs, now if we want to add SOAP APIs to the same spec/app, how can that be achieved? – Raja Kumar Thiruvasagam Jul 10 '20 at 13:10
  • That will not be a problem. You can define any number/type of APIs in a single mgw project. Just define your REST apis via APIM or by openapi definition in mgw, then import the soap APIs from APIM to same mgw project and build. Thats it. Resulting mgw will listen for all SOAP/REST endpoints defined. – Praminda Sep 10 '20 at 12:38