Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 

Please note that this blog post contains outdated information. For the latest information, please see https://blogs.sap.com/2022/08/11/configuring-sap-master-data-integration-service-for-business-partne....


(Note: Some features mentioned here might not be available in your environment. Please get in touch with SAP support if you face any such discrepancy.)

SAP Master Data Integration service serves as a central entry point for master data integration within the Intelligent Suite. There are many articles such as this one that explain how the service can help our customers achieve true integration for various Domain models in the cloud.

In this blog, I will go through the steps required to enable the SAP Master Data Integration service and replicate Business Partners. It is important to note that these steps are valid only for Business Partners replication. If your scenario requires replication of objects such as Cost center etc. then additional steps might be required.

 

I. Service Instance Creation for Business Partner Read and replicate.



  1. Go to the SAP BTP subaccount where you want the SAP MDI instance to be created. On the left-hand side, under Services, click on Instances and Subscriptions.

  2. Click on Create on the top right side.

  3. Select the service name and provide an Instance Name. Click Next.

  4. Use this JSON to create the service instance.
    {
    "businessSystemId": "<Business_System_Name>",
    "application": "<application_type>",
    "xs-security": {
    "xsappname": "<Service-Clone-Name>",
    "authorities": [
    "$XSMASTERAPPNAME.BPCommonRead",
    "$XSMASTERAPPNAME.BPSensitiveDataRead"
    ]
    }
    }​

    - Provide a service clone name, a unique v4 UUID. You can use this link to generate a v4 UUID https://www.uuidgenerator.net/

    - For BusinessSystemId, provide the logical system identifier of the client system that you will connect to the MDI instance. For E.g. if I want to connect my SAP S/4 HANA Cloud system CG4 to this system, I will use its logical system 0LOI36K.
    In SAP S/4HANA Cloud system this value is can be found under Communication systems tile and then filter by Own System.
    In SAP S/4HANA On-premise system, open transaction se37 and execute Function Module LCR_GET_OWN_BUSINESS_SYSTEM.

    - For application type, provide one value from mdg, s4, c4c, ariba, cdc, commerceCloud, hrc (SAP Subscription Billing) depending upon the type of your client system. This value is mandatory if you want to persist Key Mapping in MDI. In case your system type is not listed above, please contact SAP MDI development team.

  5. Select the service instance you created and click on Create Service Key. Click Next and then Finish.

  6. We are now done with Instance Creation for Business Partner read and replicate. Please note that for each new client system that you want to connect to MDI, you would have to follow this step again.


 


II. Setting up Generic Configuration


In this step we provide a unique identifier to the MDI tenant. This is necessary because during Key Mapping creation a corresponding MDI entry is created along with the Key Mapping of the client Business partner. At that moment, this identifier is referenced in MDI Key Mapping.

  1. Create a new MDI Service Instance. Use the below JSON to create the instance.
    {
    "xs-security":{
    "xsappname":"<service-clone-name>",
    "authorities":[
    "$XSMASTERAPPNAME.BPGenericConfigRead",
    "$XSMASTERAPPNAME.BPGenericConfigWrite"
    ]
    }
    }​

    Provide a v4 UUID for service-clone-name parameter.

  2. Generate service keys.

  3. In the Postman Client, create a POST Request for the following endpoint. This endpoint in OAuth2.0 protected. Use the service keys that were generated.
    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/odata/API_GENERIC_CONFIGURA...

    Use the following payload.
    {
    "BusConfignVersion": "4294967296",
    "BusConfignIsDeleted": null,
    "Id": "<Unique_V4_Uuid>",
    "ConfigurationName": "Business System",
    "ConfigurationValue": "<identity-zone>",
    "AllowedValues": null
    }

    Replace the identity-zone parameter value with the identityzone from the service keys. To generate a V4 UUID: https://www.uuidgenerator.net/

    Please refer to the Troubleshooting section to generate access token via the Postman client.


 

 

III. Create SOAP Outbound Destinations to the client System


The Business partner implementation in MDI utilizes the BTP subaccount destinations that are defined in a specific format.

  1. Navigate to your subaccount and click on the Destinations tab on the right side. (Your user should have relevant security authorisations)

  2. Click on "New Destination".

  3. In the Name placeholder provide value <Business_System_Name>_BPOUTBOUND. Make sure "Business_System_Name" value is the same as the one used in section I of this blog.

  4. Type: HTTP

  5. The URL placeholder value can retrieved in two ways depending upon whether your system is is a Cloud or OnPremise.
    For the S/4H OnPremise system login to your ERP system and create BP SOAP endpoint as mentioned in section IX of this blog here. Use the final URL created in this field.
    For the Cloud system, open a communication arrangement of type SAP_COM_0008 and copy the inbound Services URL.

  6. Proxy Type: OnPremise for S/4HANA on-premise system / Internet for S/4HANA Cloud system. Additionally, a cloud connector setup would be required for OnPremise systems.

  7. Username and Password for the S/4HANA system.

  8. Click on "New Property" and add MDOConsumer. Set its value True.

  9. Click on Save. The final result should look like this.

  10. Repeat steps 3-7 and create the following destination:
    a. <Business_System_Name>_BPCONFIRM
    b. <Business_System_Name>_BPRELOUTBOUND
    c. <Business_System_Name>_BPRELCONFIRMNOTE: Optionally you can also configure
    d. <Business_System_Name>_KEYMAPCONFIRM
    e. <Business_System_Name>_KMOUTBOUND
    These interfaces are part of the Communication Arrangement SAP_COM_0539 & SAP_COM_0540.


 

IV. Subscribing to Master Data Orchestration


In the sub-account, click on "Instances and Subscriptions" on the left side. Search for the "Master Data Integration (Orchestration)" service and click Subscribe.

 

V. Configuring access for Master Data Orchestration Fiori application


To view the Master Data Orchestration tiles, your user should have the necessary roles assigned to it.

  1. Under the Security dropdown on the left side, click on Role Collections. (You should have a Security Administrator authorisation to perform this step).

  2. Click on sign and create a new Role collection with the name MDOAdmin. Search for the role MasterDataOrchestrationAdmin & MasterDataOrchestrationDisplay to the role collection. Finally, add your user to the role collection.

  3. Once your user is assigned, go back to Instances and Subscriptions and click on "Go to Application".

  4. You should now have access to all the Master Data Orchestration tiles.


 

V. Creating MDO Distribution Model for Business Partner Replication



  1. Open the "Manage Distribution Model".

  2. Provide a name for the model and select "Business Partner" in the Business Object Type dropdown.

  3. Set the continuous distribution checkbox if you want the business partners to be replicated as soon as they are created/updated.

  4. Provide a value for Package Size.  Package size specifies up to how many objects are contained in a single outbound XML message from MDI to the client system

  5. Select the latest stable API : MDI_SOAP_BUSINESS_PARTNER

  6. Now, to create a Provider and Consumer, click the create button and select the provider: MDI
    Similarly for the consumer, select the target destination. You can select the appropriate "Application Category" if required.

  7. Set Data filters if required.

  8. Activate the Replication Model. The configuration is now complete. You can now replicate the Business Partners from the SAP Master Data Integration service to client systems.


 

 

Troubleshooting



  1. Checking if the Business Partner is replicated
    Using the credentials generated in Step 1 of the blog, perform a GET request on:
    https://one-mds.cfapps.<region>.hana.ondemand.com/businesspartner/v0/odata/API_BUSINESS_PARTNER/Busi... eq '<BP_Number>'

    The endpoint is OAuth2.0 protected. SAP MDI adopts the BP Number of the sender system. So, you can use the BP Number of the sender system for the GET request.

    Additionally, you can expand on an entity to see the details. Eg:
    https://one-mds.cfapps.<region>.hana.ondemand.com/businesspartner/v0/odata/API_BUSINESS_PARTNER/Busi... eq '<BP_Number>'&$expand=to_Person


  2. Accessing MDI Business Partner Endpoints
    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/soap/BusinessPartnerBulkRep...;

    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/soap/BusinessPartnerRelatio...;

    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/soap/BusinessPartnerBulkRep...;

    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/soap/BusinessPartnerRelatio...;

    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/soap/KeyMappingBulkReplicat...;

    https://one-mds.cfapps.<region>.hana.ondemand.com:443/businesspartner/v0/soap/KeyMappingBulkReplicat...;

    These endpoints are Basic Authenticated. Client_Id is the username and clientsecret is the password. Both of the values are available in the service keys of the MDI Instance.

  3. Using Postman Client with OAuth2.0 authenticated endpoints.




 
24 Comments