Skip to Content

How to connect SOAP WebServices with Integration Gateway in SMP3

I already wrote several blog posts on how to use the Integration Gateway. But till now I was always using databases as data source. Using a SOAP web service as data source is even nicer, because you can use a graphical mapping editor (part of the GWPA eclipse plugin) to define the request and response mapping.

In this tutorial we will connect a SOAP web service to SMP3’s integration gateway and realize a Query and a Read operation

How to connect SOAP WebServices with Integration Gateway in SMP3

In this example we will use the following free sample SOAP Web Service . This is a small service which will give us a list of articles. We can list all, one specific, create or delete entries.

There are many different tools to test SOAP Web Services,e.g. SOAP UI. Another free, very small and nice utility is Storm ( which I used here.


If you execute the getAll Operation you can see (at the moment) that there are two articles in the store (Black Tea and Assam Tea).

I assume that you already installed the GWPA plugin into eclipse. If not, please follow the steps as described in my previous blog post here: How to install Gateway Productivity Accelerator (GWPA) plugin for Integration Gateway

Model the OData Service

1. Open eclipse and create a new OData Development > Service Implementation Project


2. Define a project name, e.g. “ArticleService” and select the option “Create OData file manually”

3. Expand the newly created project and right click on the “model” folder inside src/main/resources and create a new OData Model

4. Provide a name for this model, e.g. DataModel (Initial model content: Blank OData model).

5. Let’s build our ODataModel the same way our SOAP web service is modeled. Create a new “Entity Type” via Drag&Drop in the odata model editor. the name of the entity set will be your collection name that is also represented in your URL when you (later) request data from the OData service. Also create via Drag&Drop the complex type Price and add the two properties Amount and Currency.


6. Then add the properties to out Article Entity Type. Normal properties are ArticleID, Name and Description. Then choose “Add Complex Property” and call it Price.


7. Select the added complex property and choose the type in the Properties > General panel. Because we previously created the complex type in our OData Model we can find “DataModel.Price” in the drop down menu.


8. Now we finished modeling the Odata service.

Implement the OData Service

1. Right click on the OData model and choose “Implement Service”. Be aware that if you change anything in the OData model you always have to re-implement the service!


2. Right click on the implemented service and choose “Select Data source”


3. Select “Query” as operation type and as data source “SOAP Service”


4. Provide the following connection details

Property Value
Operation getAll
Port Type ArticleServicePT


You can find these values by checking your wsdl file. So download the wsdl file of the SOAP web service . Open it. You can find the SOAP endpoint usually at the end of the document inside the tag <soap:address location=”….”>


The target namespace is mentioned in the beginning inside the tag <xsd:schema … targetNamespace=”…”>


The operations (tag <operation name=”…”>) can be also read out, usually wrapped by the port type (tag: <portType name=”…”>)


5. Expand the path below the OData implementation. A new SOAP operation should be added here. Right click on it and choose “Define Response Mapping”. As the name said the response mapping is responsible inside our OData service for returning data as a response to a request. Here you can also implement a custom request logic by choosing “Define Custom Logic for Request”. This is quite interesting, because in this way you have the possibility to write a Java class where you can implement filter or other operations your OData service should provide.


6. Choose “Browse…” and navigate to your downloaded wsdl file. If you don’t have downloaded it, do it now:


7. Define a message mapping. On the left side you can see the SOAP web service and on the right side our OData EntityType. Connect the properties via Drag&Drop. Don’t forget to bind also the Entity itself, from “article” to “Article”. Save the project after this actions.


8. Right click on your whole project and click “Generate and Deploy Integration Content”.


9. the Service name will be the OData Service name running on the integration gateway. The Service Namespace will be also part of the URL and additionally it defines the security profile which should be checked when accessing this OData service.


Test the OData Service

1. After successful deployment, go to your browser and open the SMP3 Management Cockpit ( https://smpserver:8083/Admin/ ). Open tab Settings > Security Profiles and create a new Security Profile called “sap” (names like the Service Namespace we defined in the previous step during deployment). then add a new authentication provider for it. In this example we will add a “No Authentication Challenge” Provider which will simply let anyone access our OData service (should be only used for testing/development purpose!). Click on “Save”.


2. Now open the Gateway Cockpit ( https://smpserver:8083/gateway/cockpit ). You should find a new service called “ArticleService”. Click on “Open Service Document”.


3. You can see the Service Document of your OData service.


4. Let’s check if our implementation is working by accessing the ArticleSet Collection, the path will be http://smpserver:8080/gateway/odata/sap/ArticleService;v=1/ArticleSet


5. As you can see we are receiving OData coming from the SOAP web service.

Extend the OData Service with other Operations

1. If we want to access a single entity, e.g. by calling inside the browser:

http://smpserver:8080/gateway/odata/sap/ArticleService;v=1/ArticleSet(‘AR-00001‘) we will get the OData error “while trying to invoke the method java.lang.String.length() of a null objectt loaded from local variable ‘s'”. And actually the OData Service is correct. We didn’t implement the Read Operation, so it can’ work…


2. So then let’s implement the OData read operation. Inside your eclipse project right click on the service implementation and choose “Select Data Source” again. This time choose operation “Read”.


3. Specify the connection details. This time we want to realize another operation, so we will specify the “get” operation of the SOAP web service.


4. Now you can see the two operations Query and Read. Right click on Read and choose “Define Request Mapping”.


5. For the Request Mapping we want to give the Primary Key (ArticleID) and the OData service should return us the corresponding object.


6. Let’s define the Response Mapping for the “Read” operation. This is straight forward…


7. After that save everything and deploy the OData Service to SMP3 (right click on the project and choose “Generate and Deploy Integration Content”)

8. If you now are accessing our OData service with a specific element you will get returned the requested element…


9. So we have now an OData service which is realizing two operations of the SOAP web service. You could now continue and realize the CREATE and DELETE operations to let the OData service provide the same functionality than the chosen SOAP web service…

I hope this tutorial is helping to understand the idea behind integrating SOAP web services with SMP 3. Unfortunately, there are many restrictions/limitations at the moment in regards to the support SOAP web services. For a list of restrictions you can check the following two SAP notes:

For GWPA eclipse plugin: 1830710 – Gateway Productivity Accelerators Release Note & Constraints > Constraints > Toolkit for Integration Gateway

For Integration Gateway: 1931374 – Integration Gateway for SAP Mobile Platform 3.0 – Known Constraints

Anyway, the integration gateway is a powerful component and will be enhanced in future…

You must be Logged on to comment or reply to a post.
  • hi Marvin

    this is the right guide i want. i could make it work by following your blog.

    it's really helpful. Really appreciate your work, and hope you could share more 😛

    but i have a few doubts:

    1. seems your source web service is very like odata CRUD service, it's very easy to use it as OData service. but it's still different from the actually project requirement. let's say we have an existed web service to get the sales order, i don't think the web service will have a getAllSalesOrder function, because the data volume is very large. so usually there will more query parameter(like start-time, end-time). in this case, which kind of operation we should use? create, update, read? definitely we cannot use query which cannot define request parameter mapping.

    2. at the end of your blog, you mentioned there are many restrictions/limitations, the restrictions/limitations means not all the web service supported by smp? cause i try some web service, in the mapping, the structure cannot display, does it mean that these kind of web service need to re-developed? or is there any specification detailed about the limitations?

    thanks a lot

    best regards


    • Hi Lawrence,

      thanks for the feedback

      to your questions:

      1) Of course it is only a simple sample web service which should show the general way on how integration gateway is working.

      You can define a custom logic for the Request Mapping when realizing the Query operation (I mentioned it shortly in step 5 of "Implement the OData service"). This means in your SalesOrder case you might have a collection/entity set called SalesOrderCollection. Because as you said you might not have a getAll function available you can have to implement some OData filter, so e.g. that you could call the OData service like this .../SalesOrderCollection?$filter=start-time eq '2014-03-16' which would show you only the sales orders from today. Instead of "equal" you can also implement other operators like greater/less or you can combine several filter. But as I said you would have to implement these filters in a Java class. If I find some time in the next week I will try to write a blog post for this...

      2) Most problem (in my opinion) is the supported compatibility of the WSDL file. I edited the blog post and inserted two SAP notes at the end which mention some restrictions. SAP Note 1830710 is the more interesting one. Check it under Constraints > Toolkit for Integration Gateway...

  • Hi Marvin,

    is it possible to create OData Service required from the Scratch or say combining multiple SOAP and Rest services, customize it and then develop new OData Service. We are encountering variety of back-ends including custom non-sap applications/portals. How to connect to NON-SAP WeB Portals and other custom web apps through integration gateway?

    • Hi Mayur,

      the SMP3.0 is still in RampUp. If you are not a RampUp customer you cannot get it. The Integration Gateway is part of the SMP 3.0 on premise version.



      • Oh You mean Integration Gateway is not available on SMP Cloud? if that is the case,how do we do testing to connect with various back-ends without integration gateway?

        Is it possible to create oData Service from scratch using Integration Gateway?if yes, which language we use to write custom logic? Is it also possible to combine multiple data sources such as one SOAP serice, One Rest Service and data from any RDMS system and create single OData Service?


        • Yes. I have the same question. For SMP 3.0, we have Integration Gateway and that will help in creating Odata services from a SOAP service or JDBC etc..using GWPA.

          When using SMP2.3 there is no such thing called Integration Gateway. But we have MBO support in SMP 2.3 but it is going to be scrapped in SMP 3.0 and hence that approach is not advisable. How do we come up with OData services with our existing SOAP web service and consume it from a REST based application using SMP 2.3?

        • In SMP Cloud you can use the Cloud Connector, but it is usually intended to work with your SAP backend systems...

          Mayur Dharukiya wrote:

          Is it possible to create oData Service from scratch using Integration Gateway?if yes, which language we use to write custom logic? Is it also possible to combine multiple data sources such as one SOAP serice, One Rest Service and data from any RDMS system and create single OData Service?


          Developing of OData Services usually consists of two steps

          1) OData Model Creation

          2) OData Service Implementation

          Both steps you can perform with GWPA. Step 2 only if you choose as backends SOAP, JDBC, ODC, JPA.

          Custom logic can be inserted (e.g. to implement your own queries) using Java.

          Combination of several backend sources should be supported soon. I am not sure if it is already possible in the current public release of GWPA.

          But REST web services are not supported with Integration Gateway at the moment.



      • Hi Marvin,

        From your blog I got to know of Integration Gateway constraints..and one of them is :

        Destination assignments through Gateway Management Cockpit are not supported. The Destination or connectivity parameters  for the SOAP services can only be maintained through the Integration Gateway eclipse plugin.

        I am trying to create OData services using a SOAP web service with requires authorization,

        How do we configure the credentials for the destination backend here in eclipse since it cant be done using gateway management cockpit?

        I tried giving "anonymous user" when I create Application in SMP admin console and I am able to successfully Register . But when I try to do a HTTP GET, I get an error like "No handler for data",

        Have you ever come across such errors?



  • It's really good step by step guide, but unfortunetely I stuck on the step 7. I download this xml and change it wsdl. On the message mapping, I only see "article" w/o further fields in the left side.

    Thanks for help.

    • Hi Chuck,

      this is a common error usually related to your network connection. When you do the mapping eclipse need to have a network connection to the SOAP web service. So check your internet connection, or if you are behind a proxy set the proxy settings inside eclipse's settings. If you now create a new mapping make sure to delete all previous (wrong mappings) stored in folder "mapping".

  • Hi Mayur,

    you can write custom logic in Java to define e.g. OData filter for SOAP Web services:


    This will create a Java file for you in which you can insert your custom logic...

  • Hi Marvin,

    In the constraints and limitations, there is one point like

    Destination assignments through Gateway Management Cockpit are not supported. The Destination or connectivity parameters for the SOAP services can only be maintained through the Integration Gateway eclipse plugin.

    I have a secured web service which requires username/password to be passed on.. how and where can we configure the credentials if it cant be done in "Destinations" in Gateway Management Cockpit? Please advice.



  • Hi Marvin,

    This is a very nice blog for startup.

    Can you please add an example on how to create models for request response type..Like if there is a method for GettingEmployeeInfo which takes in Employee numbers as input and then gives out the output how should we proceed for such a scenarios.


    Best Regards,

    Rakshit Doshi

  • Hi,

    this is Prateek ,

    I am following the same tutorial to create odata services , but while defining Port Type i am facing some issues regading Port Type.

    Please help me.

    Thanks in Advance.

  • Hi Marvin,

    Good article for starting using smp 3 and integration gateway, one question from me, how to define user and password if the web service need authentication for getting data, in case webservice from sybase mobiliser 5.1



  • Hi Experts;

    Everything goes well until I have tried to deploy the content. It has thrown below error.

    Deployment cannot be completed for IGW_EPM_DEMO

    Thu Jan 29 17:18:30 IST 2015 | Validator Logs :

    Thu Jan 29 17:18:30 IST 2015 | ERROR : Enter a condition that starts and ends with header/body/constant <IFlowEditor/etype:SequenceFlow/eid:_SequenceFlow_14/>

    Thu Jan 29 17:18:30 IST 2015 | ERROR : Runtime does not support the flow element gw_converter <Project/location:Project>

    Thu Jan 29 17:18:30 IST 2015 | ERROR : Runtime does not support the flow element gw_converter <Project/location:Project>

    Thu Jan 29 17:18:30 IST 2015 | ERROR : Runtime does not support the flow element gw_converter <Project/location:Project>

    Thu Jan 29 17:18:30 IST 2015 | INFO : Mapping Completion Check is successful <mmap>

    Thu Jan 29 17:18:30 IST 2015 | INFO : Mapping Location Check is successful <mmap>

    Thu Jan 29 17:18:30 IST 2015 | INFO : Source/Target check completed successfully <mmap>

    Thu Jan 29 17:18:30 IST 2015 | Generation started for IGW_EPM_Demo project

    Thu Jan 29 17:18:30 IST 2015 | Generation and build failed for IGW_EPM_Demo as validation of resource is failed

    Thu Jan 29 17:18:30 IST 2015 | Deploy skipped; project list is empty

    Thu Jan 29 17:18:30 IST 2015 | Generation, build and deploy failed for task 562ef794-010e-45ef-b47e-33f870708a7d



  • Hi All,


    I am facing one problem with my web service call that when i am calling from  SMP i am getting mapping error in which it is asking for input mapping name expected error ,that i have already set via js custom code .

    Plase help me with this.