# mulesoft Consumer Goods - Full Documentation --- product: Consumer Goods version: 5.3 is-latest-version: true --- # MuleSoft Accelerator for Consumer Goods > For the full documentation index, see: https://docs.mulesoft.com/llms.txt MuleSoft Accelerator for Consumer Goods helps consumer goods companies integrate their digital operations to gain visibility into trade promotion management and retail execution. Our foundational assets are expertly designed to jumpstart your top integration and business initiatives so that IT teams can spend more time innovating and less time building from scratch. ## Use Cases ### Product and Account Integration with Hierarchies The [Product and Account Integration with Hierarchies](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/minor/5.3/pages/q2e-w7j/Use%20case%201%20-%20Product%20and%20Account%20Integration%20with%20Hierarchies/) use case surfaces relevant product, customer, demand planning, and pricing information from ERP and PIM systems and easily consolidate this information into Trade Promotion Management (TPM) platforms like Salesforce Consumer Goods Cloud for informed promotional planning. ### Retail Execution The [Retail Execution](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/minor/5.3/pages/Use%20case%202%20-%20Retail%20execution/) use case unlocks shelf data to enable perfect retail execution with pre-built assets. Access store audit data from image recognition software, like Trax, and smoothly integrate into Retail Execution platforms, such as Salesforce Consumer Goods Cloud, to monitor at shelf performance in one platform. ### Trade Promotion Effectiveness The [Trade Promotion Effectiveness](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/minor/5.3/pages/phi-ime/Use%20case%203%20-%20Trade%20promotion%20effectiveness/) use case allows you to visualize your promotions in one integrated platform with pre-built assets that integrate Business Intelligence Tools (BI Tools), such as CRM Analytics, into a TPM platform like Salesforce Consumer Goods Cloud. ### Trade Promotion Optimization The [Trade Promotion Optimization](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/minor/5.3/pages/uo5-830/Use%20case%204%20-%20Trade%20promotion%20optimization/) use case allows you to visualize your promotions in one integrated platform with pre-built assets that integrate Business Intelligence Tools (BI Tools), such as CRM Analytics, into a TPM platform like Salesforce Consumer Goods Cloud. ### POS Integration The [POS Integration](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/minor/5.3/pages/ebd-knq/Use%20case%206%20-%20POS%20integration/) use case enables retail developers to leverage pre-built integrations to connect order and loyalty data from Point of Sale (POS) systems to Data Cloud. ### Pricing Data integration for Trade Promotion Management The [Pricing Data Integration for TPM](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/minor/5.3/pages/3hl-pip/Use%20case%207%20-%20Pricing%20Data%20Integration%20for%20TPM/) use case enables consumer packaged goods companies to more effectively analyze and optimize promotional activities by integrating List Price and Cost of Goods Sold data with Hyperforce. ## See Also - [Getting Started](https://docs.mulesoft.com/accelerators-home/getting-started) - [Prerequisites](https://docs.mulesoft.com/consumer-goods/latest/prerequisites) - [Release Notes](https://docs.mulesoft.com/release-notes/accelerators/consumer-goods/consumer-goods-release-notes) - [MuleSoft Accelerator for Consumer Goods on Exchange](https://anypoint.mulesoft.com/exchange/org.mule.examples/mulesoft-accelerator-for-consumergoods/) --- product: Consumer Goods version: 5.3 is-latest-version: true --- # Prerequisites for MuleSoft Accelerator for Consumer Goods > For the full documentation index, see: https://docs.mulesoft.com/llms.txt This page provides a summary of the guides available for configuring the various systems and products required to implement the use cases provided by this solution. The individual systems needed, and amount of configuration required, depend on which assets are to be deployed in your target environment(s) - refer to the use case pages for more details. ## Available Guides The following setup and configuration guides are available for this accelerator: - [SAP S/4HANA Setup Guide](https://docs.mulesoft.com/consumer-goods/latest/sap-s4hana-setup-guide) Most of the implementation templates also contain details on requirements specific to those applications. ## See Also - [Getting Started](https://docs.mulesoft.com/accelerators-home/getting-started) - [MuleSoft Accelerator for Consumer Goods](https://docs.mulesoft.com/consumer-goods/latest/) --- product: Consumer Goods version: 5.3 is-latest-version: true --- # SAP S/4HANA Setup Guide > For the full documentation index, see: https://docs.mulesoft.com/llms.txt The following describes how to configure and test an S/4HANA Cloud SOAP outbound service (Product replication: `productmdmbulkreplicaterequest`) and the S/4HANA Cloud SOAP Connector as a Mule application deployed on Cloudhub. ## Configurations in S/4HANA To make the necessary configurations in S/4HANA: 1. Create a **Communication System** in the corresponding Fiori app. This communication system represents the external system that will consume the S/4HANA Cloud SOAP service. In this example, it’s named "COM\_0009\_SOAP\_OUT": ![SAP S/4HANA Create Communication System](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-01.png) 2. For the 'Business System' name, use the same name of the System ID. 3. In the 'Host Name' field, enter the hostname of the Mule application deployed on Cloudhub (if you don’t have it yet, you can enter a mock URL and then modify it later): ![SAP S/4HANA Communication System with Host Name field](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-02.png) 4. Create a user that will be used to connect to the Cloud Hub app for sending product information in the outbound scenario (this is necessary even though the Mule application does not validate the user; we used any user for outbound): ![SAP S/4HANA user creation](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-03.png) 5. Use the **Communication Arrangement** Fiori app to create a new Communication Arrangement: ![SAP S/4HANA Create Communication Arrangement](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-04.png) 6. Create a new **Communication Arrangement**, select the communication scenario "SAP\_COM\_0009", and then define a specific name for the arrangement, "SAP\_COM\_0009\_SOAP". 7. In the **Communication System** field, select the Communication System created in the previous step: ![SAP S/4HANA Communication Arrangement with Communication System selected](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-05.png) 8. For outbound communication, select the previously-created user and configure the **Product Master - Replicate from SAP S/4HANA Cloud to Client** and include the following settings. Make sure to note the Path (`/sap/bc/srt/scs/sap/productmdmbulkreplicaterequest`) because we will use this path to configure the Mule application SOAP endpoint: - Set the Service status to **Active** - Replication Model (any name) - Replication model = I (Initial) - The Output Mode = D (Direct). ![SAP S/4HANA outbound service with Service Status set to Active](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-06.png) ![SAP S/4HANA outbound service Replication Model settings](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-07.png) ![SAP S/4HANA outbound service Output Mode settings](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-08.png) 9. Save it. All configurations at S/4HANA Cloud side are finished and you will be able to download the WSDL that contains the metadata to import into the S/4HANA Cloud SOAP Connector into the Mule application. ## Configurations in the Mule Application The following example describes how to create a Mule application using the Outbound Message Listener operation of MuleSoft’s SAP S/4HANA SOAP Connector: 1. Create a Mule project and add the appropriate connector from Exchange to the Mule Palette: ![Anypoint Studio Mule Palette with SAP S/4HANA SOAP Connector](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-09.png) 2. Add and configure the **Outbound Message Listener** to the canvas: ![Anypoint Studio Outbound Message Listener configuration](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-10.png) 3. Add the corresponding WSDL path to the WSDL you downloaded from S/4HANA Cloud and create the HTTP listener configuration: ![Anypoint Studio SAP S/4HANA SOAP Connector WSDL configuration](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-11.png) ![Anypoint Studio HTTP Listener configuration](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-12.png) _\*Note\*: we are using no authentication on the Mule Application, so we used the Insecure option for the Trust Store Configuration. In the Keystore configuration, we used a test Keystore, which is mandatory for HTTPS communication:_ ![Anypoint Studio TLS configuration with insecure trust store](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-13.png) 4. Select the Message type that the connector expects to receive from SAP (the connector reads the metadata from the WSDL we configured): ![Anypoint Studio SAP S/4HANA SOAP message type selection](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-14.png) 5. On the Responses tab, use the status Code "202" and the Reason-Phrase "Accepted" because we want to send the same status that S/4HANA Cloud will send if the service invocation results OK. No payload will be returned as a response—​just the Status code and Reason-phrase: ![Anypoint Studio response configuration with HTTP status 202 Accepted](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-15.png) 6. Use a **Logger** component to log the inbound XML payload: ![Anypoint Studio Logger component configuration](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-16.png) _The Mule flow should look like the following:_ ![Anypoint Studio flow for receiving SAP S/4HANA product replication messages](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-17.png) 7. Deploy the application to Cloudhub. You’re now ready to test the scenario. ## Testing the scenario To test the scenario: 1. Create the following. You only need to create a material in the corresponding Fiori app of S/4HANA Cloud: ![SAP S/4HANA material creation](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-18.png) ![SAP S/4HANA material data entry](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-19.png) ![SAP S/4HANA material configuration](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-20.png) ![SAP S/4HANA material save](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-21.png) _After you save the new material, you should see the following confirmation in S/4HANA Cloud:_ ![SAP S/4HANA confirmation that the material was saved](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-22.png) _The following shows the XML message received at the Mule application at the Runtime Manager on Cloudhub:_ ![Anypoint Runtime Manager log with the received product replication message](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-23.png) 2. See the sent message in the Message Dashboard Fiori Application: ![SAP S/4HANA Message Dashboard with sent product replication message](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-24.png) 3. Select the date: ![SAP S/4HANA Message Dashboard date selection](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-25.png) 4. Search under **CMD:Product Integration - /CMDPR → Product Replication to Client via Service - PRDREQ\_OUT/00001 namespace**: ![SAP S/4HANA Message Dashboard search for product replication messages](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-26.png) ![SAP S/4HANA product replication message details](/mulesoft/current/en-us/retail/latest/_images/retail-sap-s4hana-setup-guide-27.png) ## S/4HANA customization guide The following provides guidance on the custom fields that you must create for both the customer and order sync use cases to function in an end-to-end manner. Create the following new fields in the corresponding objects for the use case:
Salesforce ObjectField NameData TypeLengthUniqueExternalId

BusinessPartner

YY1_SME_MPARTYROLEID_bus

Text

36

Y

Y

SalesOrder

YY1_SME_MORDERID_SDH

Text

36

Y

Y

Product

YY1_SME_UnvProductId_PRD

Text

36

Y

Y

The following provides guidance on the custom fields that you must create for both the customer and product sync from SAP S/4HANA to Salesforce Consumer Goods Cloud. Create the following fields using the app Custom fields:
SAP Field NameLabelData TypeLengthSAP Business Context

YY1_SME_ParentID_RTL

Parent ID

Text

10

Master Data: Business Partner

YY1_SME_AccouTemp_RTL

Account template

Text

50

Master Data: Business Partner

YY1_SME_KAM_Prod_RTL

KAM Products

Text

40

Master Data: Product General

YY1_SME_Comp_Prod_RTL

Competitive Product

Checkbox

1

Master Data: Product General

YY1_SME_Prod_Temp_RTL

Product template

Text

50

Master Data: Product General

YY1_SME_Prod_Code_RTL

Product code

Text

50 Master Data: Product General

YY1_SME_Shrt_PCode_RTL

Short Product Code

Text

40

Master Data: Product General

YY1_SME_Sell_Code_RTL

Sell in Code

Text

40

Master Data: Product General

YY1_SME_Asset_Temp_RTL

Asset Template

Text

20

Master Data: Product General

YY1_SME_PackSize_RTL

Pack Size

Decimal

12

Master Data: Product General

YY1_SME_PackSizeUn_RTL

Pack Size Unit

Text

10

Master Data: Product General

YY1_SME_ProdForm_RTL Product Form

Text

10

Master Data: Product General

YY1_SME_Category_RTL

Category

Text

40

Master Data: Product General

YY1_SME_SubCategor_RTL

SubCategory

Text

40

Master Data: Product General

YY1_SME_Brand_RTL

Brand

Text

40

Master Data: Product General

YY1_SME_Flavor_RTL

Flavor

Text

40

Master Data: Product General

YY1_SME_Package_RTL

Package

Text

40

Master Data: Product General

YY1_SME_Prod_Desc1_RTL

Description 1

Text

50

Master Data: Product General

YY1_SME_Prod_Desc2_RTL

Description 2

Text

40

Master Data: Product General

YY1_SME_DlvValFrom_RTL

Delivery Valid From

Date

N/A

Master Data: Product General

YY1_SME_FieldValFr_RTL

Field Valid From

Date

N/A

Master Data: Product General

YY1_SME_KAMValFrom_RTL

KAM Valid From

Date

N/A

Master Data: Product General

YY1_SME_NewItmVldF_RTL

New Item Valid From

Date

N/A

Master Data: Product General

YY1_SME_FundValiFr_RTL

Fund Valid From

Date

N/A

Master Data: Product General

YY1_SME_DlvValThru_RTL

Delivery Valid Thru

Date

N/A

Master Data: Product General

YY1_SME_FieldValTh_RTL

Field Valid Thru

Date

N/A

Master Data: Product General

YY1_SME_KAMValThru_RTL

KAM Valid Thru

Date

N/A

Master Data: Product General

YY1_SME_NewItmVldT_RTL

New Item Valid Thru

Date

N/A

Master Data: Product General

YY1_SME_FundValiTh_RTL

Fund Valid Thru

Date

N/A

Master Data: Product General

YY1_SME_ManItemNmb_RTL

Manufacturer Item Number

Text

20

Master Data: Product General

YY1_SME_EstimValue_RTL

Estimated Value

Text

20

Master Data: Product General

YY1_SME_PowSuppCon_RTL

Power Supply Connected

Checkbox

N/A

Master Data: Product General

YY1_SME_HierarchID_RTL

Hierarchy Identifier

Code List

2

Master Data: Product General

As YY1\_SME\_HierarchID\_RTL data type is Code list, the possible values for are:
Code ValueDescription

CA

Category

SU

Subcategory

BR

Brand

FL

Flavor

PR

Product

On the section ‘UIs and Reports’ for each field enable the corresponding UI app (Business Partner or Product basic data) and the option OData extension model and publish. To add the fields into each app, use the option Adapt UI from your profile. ## See Also - [Prerequisites](https://docs.mulesoft.com/consumer-goods/latest/prerequisites) - [MuleSoft Accelerator for Consumer Goods](https://docs.mulesoft.com/consumer-goods/latest/)