SAP PI/PO Adapter

  1. Home
  2. Docs
  3. SAP PI/PO Adapter
  4. 2. How to create an inbound interface to post a hierarchical sObject using the SKYVVA connector module?

2. How to create an inbound interface to post a hierarchical sObject using the SKYVVA connector module?

This Document explains you on how to create an inbound interface to post a Hierarchical sObject using the Skyvva connector module.

  • Overview: 

This is an inbound asynchronous interface to Import SAP Debitors with its Sales Area Data and Partner Roles to Salesforce from SAP ERP system using SAP PO as middleware.

Initially, We have to create four inbound interfaces. One is the parent and the rest of the three are child interfaces.

  • Account_IN
  • Contact_IN
  • SAPPartnerRole
  • SAPAccountSalesArea_IN

Login to the Salesforce org and then select Skyvva Integration Cloud.

Go to Integration Tab and create New Integration under that go to the interfaces tab and then create all the four interfaces as shown below.

  • Account_IN

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

  • Contact_IN

Now create contact inbound interface

 

 

 

 

 

 

 

 

 

 

Add Parent Interface as Account interface as shown above.

 

 

 

 

 

 

 

 

 

 

 

 

Create Foreign key lookup to link the contact to an Account as shown below.

 

 

 

 

 

 

  • SAPPartnerRole_IN

Create SAPPartnerRole_IN inbound interface as shown below.

 

 

 

 

 

 

 

 

 

 

Add Parent Interface as Account interface as shown above.

 

 

 

 

 

 

 

 

 

 

 

Create Foreign key lookup to link SAPPartnerRole to an Account Interface as shown below.

 

 

 

 

 

 

SAPAccountSalesArea_IN

Create SAPAccountSalesArea_IN inbound interface as shown below.

 

 

 

 

 

 

 

 

 

 

Add Parent Interface as Account interface as shown above.

 

 

 

 

 

 

 

 

 

 

 

Create Foreign key lookup to link SAPAccountSalesarea to an Account Interface as shown below.

 

 

 

 

 

 

 

Now add Contact_IN, SAPPartnerRole_IN, and SAPAccountSalesArea_IN interfaces as child interfaces to parent Account interface.

 

 

 

 

 

 

Now generate the WSDL for Account_IN and upload it into SAP PO for Mapping.

 

 

 

 

 

 

 

 

 

 

 

Click on View to download the WSDL.

WSDL looks like below

 

 

 

 

 

 

Under the parent Account we can see three child objects as shown below.

 

 

Import WSDL into ESR

First, we have to create a namespace in ESR like „http://XXXXX/Account

Now create an external definition under the namespace like below. Here the WSDL is for Account. So, we can give the name as Account_IN

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Now import the WSDL and Save and activate it.

Similarly, import the IDOC „DEBMAS07“ from SAP. This IDOC itself used as a data type, Message type, and service interface.

 

Create a service interface under the namespace.

Choose the category Inbound or Outbound. In our scenario we are creating an inbound interface, therefore we choose Inbound and also its an asynchronous inbound interface So we choose the mode as Asynchronous.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Now import the external definition and then click on save and activate the inbound service interface.

Message mapping

Create message mapping under the same namespace.

Select the Source structure as DEBMAS07 and the target structure will be the external definition which we downloaded from Salesforce.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Do the respective mapping and save and activate.

Here we have to define the parameters for Account, Contact, PartnerRole, and for AccountSalesArea to pass the values in runtime.

 

 

 

 

 

 

Now we have to bind these parameters in the operation mapping.

  • Operation Mapping for asynchronous inbound interface

Create Operation mapping.

Choose the inbound and outbound service interface and the respective message mapping.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Now we have to define the parameters here.

 

 

 

 

 

 

 

 

 

We have to bind the message mapping parameters with operation mapping parameters as shown below.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Then save and activate the operation mapping.

  • Creation of Integration Flow

After creating the objects in ESR. We have to configure these objects in the integration directory.

First, we have to create Integration flow in NWDS. Give the relevant name as for example „IF_SAP_to_Salesforce_Account

Integration flow has the following objects.

  • Business System for Sender and Receiver
  • Sender and Receiver Communication channel
  • Integrated Configuration

 

 

 

 

 

 

 

 

 

These are the objects we should create.
We have to define our business system e.g. for the SAP-Backend. For Salesforce you can use our proposal “Salesforce” as the business system. We have to import these business systems from SLD.

  • Configuring the Sender Idoc communication channel

Create sender communication channel as shown below.

Since we are using an IDOC as a source. So, here we are using IDoc adapter in the sender channel.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Provide the necessary details. After that save and activate the channel.

  • Configuring the SOAP receiver channel

Configuration for Tab “General”

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Specify the parameters as shown in the above screenshot.

Below is the configuration for the “Advanced” Tab.

 

 

 

 

 

 

 

 

 

 

The value “TserverLocation” has to be entered for the parameter Variable Header (XHeaderName1).

Below are the settings for Tab “Module”. Here, the SKYVVA module containing the logic for session handling.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Configuration of module parameters are described in detail below

  • Skyvva Module Parameters

Starting from version 2.27 Skyvva provides a single module, “Salesforce/GetSessionID_V4”, to be used with SOAP receiver channels. Module parameters are outlined below

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

  • Creating I-flow in NWDS

Create an I-Flow as „IF_SAP_2_SF_Account as shown below

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Select the point to point channel because here we are sending data to one receiver only then click on next.

Provide the sender system and the receiver system details as shown below and then click on finish.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Assign the sender and the receiver channel and the operation mapping.

 

 

 

 

 

 

 

 

 

 

After adding all the details the flow will look like below.

 

 

 

 

 

 

 

 

 

 

 

Specify the parameter values to which we defined in ESR.

 Test the Inbound Interface.

IDOC DEBMAS07 has been triggered by ECC. Now we have to check the result in Salesforce Skyvva message board.

 

 

The message got successfully posted to Salesforce. Below is the screenshot to show the parent Account with the child Contacts, partner roles, and AccountSalesArea.

 

 

 

 

 

 

 

Was this article helpful to you? Yes No

How can we help?