MuleSoft Accelerator for Manufacturing icon

MuleSoft Accelerator for Manufacturing

(0 reviews)

Use case 1 - Account and product and order sync

Unlock account (customer), product, and order data from SAP S/4HANA and sync it with Salesforce Manufacturing Cloud in real time or batch to streamline sales agreements and account forecasts.

Contents

See also

Overview

In any capital-intensive manufacturing organization, complete visibility into account, product and order data is critical to the organization’s success.

The purpose of this use case is to enable predictability to drive success for both customers and manufacturers. The solution helps to reveal a single view of your account, product and order data to help you manage your manufacturing business with confidence.

Use case description

This use case extracts account, product and order data from SAP S/4HANA into Salesforce Manufacturing Cloud with pre-built APIs and templates. Connecting this critical data to Sales allows you to create an effective sales forecast.

While we base the use case on SAP S/4HANA and Salesforce Manufacturing Cloud, we take an API-led approach to integration so that all endpoints can be replaced with your systems of choice.

Glossary

TermDefinition
MFGAbbreviated term referring to the Manufacturing industry.
CIMThe Cloud Information Model for MuleSoft Accelerators defines a set of standard data structures that can be used as canonical representations of common entities for integrating systems.

Use case considerations

Functional considerations

  • Support account, product and order sync to Manufacturing Cloud in real-time or batch mode from the system of record.
  • Accounts are synced from SAP S/4HANA to Manufacturing Cloud and are available to search and select when creating a Sales Agreement. The following functionality is supported:
    • Create new accounts
    • Update existing accounts
    • Create account hierarchies
    • Update account hierarchies
  • Products are synced from SAP S/4HANA to Manufacturing Cloud. The following functionality is supported:
    • Create new products
    • Update existing products
    • Associate products to categories or sub-categories
    • Associate products to a product catalog (Note: While only one catalog is supported currently, the solution can be extended to support multiple catalogs)
  • Orders are synced from SAP S/4HANA to Manufacturing Cloud and can be associated with a Sales Agreement. Orders are created in Salesforce Manufacturing Cloud and can be associated with a Sales Agreement based on the following conditions being met:
    • Sales Agreement is active.
    • Customer in the order matches the Account in the Sales Agreement.
    • Product level is Product and the product in the order matches a product in the Sales Agreement, or product level is Category and the product’s primary category from the order matches a category in the Sales Agreement.

Technical considerations

This section lists the technical considerations and constraints on the solution design.

  • SAP S/4HANA is the system of record for customers, products and orders
  • Customers, products and orders can be synced in real-time or batch
  • Sync is unidirectional from SAP S/4HANA to Manufacturing Cloud
  • External identifiers are created for accounts, products and orders being synced and are stored in SAP S/4HANA and Manufacturing Cloud so that the objects can be corelated across the two systems.

End-to-end scenarios

  • Product and Product Hierarchy created or updated in SAP S/4HANA is reflected in Salesforce Manufacturing Cloud.
  • Account and Account Hierarchy created or updated in SAP S/4HANA is reflected in Salesforce Manufacturing Cloud.
  • Order created in SAP S/4HANA is reflected in Salesforce Manufacturing Cloud.

Solution definition

The primary set of use cases covered in the current solution involve the synchronisation of account, account hierarchy, product, product hierarchy and order data between multiple systems.

Goal

Product synchronisation to Salesforce Manufacturing Cloud.

Main success scenario

  1. Receive a new or updated product from SAP S/4 HANA.
  2. Attempt to match the input to an existing product in Salesforce Manufacturing Cloud.
  3. If a match is found, update the existing product Salesforce Manufacturing Cloud. If no match is found, create a new product in Salesforce Manufacturing Cloud.

Goal

Account synchronisation to Salesforce Manufacturing Cloud.

Main success scenario

  1. Receive a new or updated account from SAP S/4HANA.
  2. Attempt to match the parent account ID to an existing account in Salesforce Manufacturing Cloud. This step is performed for every parent in the hierarchy.
    • If a match is found, retrieve the existing entry in Salesforce Manufacturing Cloud. If no match is found, create a new entry in Salesforce Manufacturing Cloud.
  3. Attempt to match the account to an existing account in Salesforce Manufacturing Cloud.
    • If a match is found, update the existing entry in Salesforce Manufacturing Cloud. If no match is found, create a new entry in Salesforce Manufacturing Cloud.

Goal

Order synchronisation to Salesforce Manufacturing Cloud.

Main success scenario

  1. Receive a new order from SAP S/4HANA.
  2. Attempt to match the account and product in the order to an existing account and product in Salesforce Manufacturing Cloud.
  3. Look up a sales agreement corresponding to the account and product in Salesforce Manufacturing Cloud.
  4. If a corresponding sales agreement is found, create a new order associated with the sales agreement in Salesforce Manufacturing Cloud. If not found, create a new order without associating it with a sales agreement in Salesforce Manufacturing Cloud.

Assumptions and constraints

The following will be used to guide or constrain the solution design at a high level:

  • The Cloud Information Model will be used as the canonical model for all business types; see the CIM usage guidelines in that asset.
  • Universal identifiers will be maintained in Salesforce Manufacturing Cloud. Wherever possible, these will be assigned as external identifiers in target systems.
  • References to the universal IDs will be reflected in Salesforce Manufacturing Cloud using ExternalIDs to avoid conflicts with the usage of other external identifiers.

High-level architecture

Product Customer and Order sync HLA

Activity diagram

The activity diagrams below illustrate the sequence of synching account, product and order data to Salesforce Manufacturing Cloud from SAP S/4HANA.

Product sync batch

Product sync batch sequence diagram

Product sync real-time

Product sync real-time sequence diagram

Account sync batch

Account sync batch sequence diagram

Account sync real-time

Account sync real-time sequence diagram

Order sync real-time

Order sync real-time sequence diagram

Processing logic

The primary handling and orchestration of products will be implemented in the MFG Products Process API. This process can be described as follows:

  1. A product has the catalog and category attributes that represent the product hierarchy. Note that the product hierarchy is also synced across the two systems.
  2. The bulk data upload to Manufacturing Cloud will be implemented using a batch scope where each of the steps from Step 3 - Step 6 will happen in parallel for all the products.
  3. SAP S/4HANA System API will retrieve the product and product hierarchy if applicable.
  4. Find a matching product entry in Salesforce Manufacturing Cloud. The lookup will be done by attempting to match on the external identifier.
  5. If a single match is found, apply the incoming updates to the existing product in Salesforce Manufacturing Cloud.
  6. If no match is found, create a product entry in Salesforce Manufacturing Cloud with the external identifier.

The primary handling and orchestration of customers will be implemented in the MFG Customers Process API. This process can be described as follows:

  1. A customer has an attribute to identify the parent (parentId) that represents the hierarchy where each parent is a type of customer. Note that the customer hierarchy is also synced across the two systems.
  2. The bulk data upload to Manufacturing Cloud will be implemented using a batch scope where each of the steps from Step 3 - Step 6 will happen in parallel for all the customers.
  3. SAP S/4HANA Customer System API will retrieve the customer and customer hierarchy if applicable.
  4. Find a matching customer entry in Salesforce Manufacturing Cloud. The lookup will be done by attempting to match on the external identifier.
  5. If a single match is found, apply the incoming updates to the existing account in Salesforce Manufacturing Cloud.
  6. If no match is found, create a customer entry in Salesforce Manufacturing Cloud with the external identifier.

The primary handling and orchestration of orders will be implemented in the MFG Orders Process API. This process can be described as follows:

  1. Receive a new order from SAP S/4HANA Event Listener as an event.
  2. Attempt to match the input to an existing customer and product in Salesforce Manufacturing Cloud.
  3. Retrieve the salesforce product details from Salesforce Products System API and account details from Salesforce Customers System API.
  4. Attempt to retrieve the sales agreement ID matching the account and product in Salesforce Manufacturing Cloud.
  5. If a corresponding sales agreement is found, create a new order associated with the sales agreement in Salesforce Manufacturing Cloud. If not found, create a new order in Salesforce Manufacturing Cloud.

Successful outcome

After successfully completing the update processing for all target systems, the following conditions will be met:

  1. Salesforce Manufacturing Cloud holds a record of the product, customer and order.
  2. The entities in both systems will hold a reference to an external identifier
  3. Salesforce Manufacturing Cloud holds all external identifiers associated with the product, customer and order.
  4. A complete view of the product, customer and order can be constructed by retrieving the universal copy from Salesforce Manufacturing Cloud.

Systems involved

  • Salesforce Manufacturing Cloud
  • SAP S/4HANA

Setup instructions

Saleforce Manufacturing Cloud configuration

This configuration is described in the MFG Salesforce Customers System API.

SAP S/4HANA configuration

Technical Objects

  • Communication ArrangementBelow are the communication arrangements required for this use case:
Communication Arrangement IDService NameProtocol
SAP_COM_0009Products to Product Hierarchies Assignment - Read, CreateOData V4
  • Custom fields

Create the following fields using the app Custom fields:

SAP Field NameLabelData TypeLengthSAP Business Context
YY1_SME_HierUpdate_MFGHierarchy update flagCheckbox1Master Data: Product General (PRODUCT)

On the section ‘User Interfaces’, for each field enable the UI app Product basic data and the option OData extension model and publish.

To add the field into each app, use the option Adapt UI from your profile.


Before you begin


bulb.png The Getting Started with MuleSoft Accelerators guide provides general information on getting started with the accelerator components. This includes instructions on setting up your local workstation for configuring and deploying the applications.

Downloadable assets

System APIs

Process APIs

Experience APIs

Listeners

Common services (can be used across any use case)


Reviews

TypeCustom
OrganizationMulesoft Inc.
Published by
MuleSoft Solutions
Published onOct 27, 2023
Asset overview

Asset versions for 1.4.x

Asset versions
VersionActions
1.4.0