{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":37921,"path":"order-management/setup_logik_io_configuration_for_salesforce_rlm.md","title":"Configuring CPQ for SalesForce RLM","bundle":null,"doc_type":null,"release":"australia","body":"\n# Configuring CPQ for SalesForce RLM\n\nInstall and configure the Salesforce Revenue Lifecycle Management package for CPQ \\(v0.3 or later\\).\n\n## Prerequisites\n\nThis guide assumes the following:\n\nSalesforce \\(SF\\) environment:\n\n-   Your Salesforce environment has Revenue Lifecycle Management \\(RLM\\) license\\(s\\) provisioned.\n-   The setup steps described in [Salesforce RLM documentation](https://help.salesforce.com/s/articleView?id=sf.revenue_lifecycle_management_get_started.htm&type=5) are complete:\n    -   Enable RLM features in your SF org\n    -   [Enable Product Configurator](https://help.salesforce.com/s/articleView?id=ind.product_configurator_enable_product_configurator.htm&type=5)\n    -   Set up your user permissions set licenses and permission set groups for Admin user\n\nNote that Salesforce Development states that its RLM and CPQ apps are incompatible. Therefore, follow these steps:\n\n-   Uninstall the CPQ app, if it is installed.\n-   Uninstall any Salesforce CPQ for CPQ package that may be installed on the Salesforce environment.\n-   If the CPQ environment previously had a Salesforce Subscription Management for CPQ package installed on it, this must be uninstalled. Some Subscription Management package elements conflict with the elements installed by the Salesforce Revenue Lifecycle Management for CPQ package.\n\nCPQ base package: Salesforce for CPQ Base package v2.2, or greater installed.\n\n## Set up CPQ Configuration for SalesForce RLM\n\nThis guide walks you through the installation and setup of the Salesforce Revenue Lifecycle Management package for CPQ v0.3 or later. \\(This guide does not discuss NGP setup. It will be added in a later version.\\)\n\nAs the current package is unmanaged, you will be required to uninstall v0.3 to install future releases of this package.\n\n## Salesforce Product Catalog Management \\(PCM\\) → Setup Configurable Product Bundle\n\n1.  App Launcher → Price Books: Activate \"Standard Price Book\"\n2.  App Launcher → Product Selling Models: Create a new Product Selling Model \\(PSM\\)\n    -   PSM Name: \"One Time\"\n    -   Selling Model Type: \"One Time\"\n    -   Status: \"Active\"\n\n        \\[Omitted image \"cpq-product-selling-model-details.png\"\\] Alt text: Product selling model screen\n\n3.  Setup → Object Manager → Price Book Entry → Page Layouts → \"Price Book Entry Layout\": Add \"Product Selling Model\" field to the layout\n4.  Setup → Object Manager → Product → Page Layouts → \"Product Layout\": Add the following fields to the layout\n    -   Configure During Sale - makes the product configurable or not\n    -   Based On - associates a product to a class\n    -   Display URL - used for product images\n    -   Product Type\n    -   Tax Policy\n5.  Add the following related lists to the Product Layout\n    -   Product Selling Model Options\n    -   Overridden Inherited Attributes\n    -   Child Components\n    -   Inherited Attributes\n    -   Product Component Group\n6.  App Launcher → Product Catalog Management → Product Classification: Create a new Product Classification\n    -   Name: “Server Racks”\n    -   Code: “RACK”\n    -   Status: Active\n7.  App Launcher → Product Catalog Management → Products: Create a new Product\n\n    -   Product Name: “Product Warranty - 1 Year”\n    -   Active: true\n    -   Product Code: “WARRANTY”\n    -   Configure During Sale: “Not Allowed”\n    -   Product Type: “— None —\"\n    -   Description: “Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt.”\n    On the related list of the product, add a new Product Selling Model Option named \"One Time.\"\n\n    Click \"Add Price Book Entry\" in the Price Books related list, and use the following options:\n\n    -   Product Selling Model: \"One time\"\n    -   List Price: 2000\n    -   Active: True\n    -   Price Book: Standard Price Book\n8.  App Launcher → Product Catalog Management → Products: Create another new Product\n\n    -   Name: “Server Rack”\n    -   Active: True\n    -   Product Code: “RACK“\n    -   Configure During Sale: “Allowed”\n    -   Based On: “Server Racks”\n    -   Product Type: “Bundle”\n    -   Display URL: https://someimage.jpg\n    -   Product Description: “Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt.”\n    On the related list of the product, add a new Product Selling Model Option named \"One Time.\"\n\n    Click \"Add Price Book Entry\" in the Price Books related list, and use the following options:\n\n    -   Product Selling Model: \"One time\"\n    -   List Price: 150000\n    -   Active: True\n    -   Price Book: Standard Price Book\n    On the related list of the product, create a new Product Componnent Group with the following options:\n\n    -   Product Component Group Name: “Warranties”\n    -   Code: “WARRANTY”\n    -   Sequence: 0\n    -   Min Bundle Components: 0\n    -   Max Bundle Components: 2\n    -   Description: “Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt.”\n    On the related list of the \"Server Rack\" product, click \"Add\" on the Child Components related list, and add \"Product Warranty - 1 Year\" as a child component with the following options:\n\n    -   Sequence: 0\n    -   Quantity: 1\n    -   Group: “Warranties”\n    -   Allow quantity changes: true\n    -   Price includes component: false\n    -   Include component by default: true\n    -   Min Quantity: 1\n    -   Max Quantity: 3\n    -   Product Relationship Type: \"Bundle to Bundle Component Relationship\"\n    Notes:\n\n    -   You need to search this and type it - the dropdown is not automatic.\n    -   After manually opening the Bundle-to-Bundle Component Relationship record from App Launcher → Product Relationship Types, the record appears in this menu:\n\n        App Launcher → Product Relationship Types → Bundle to Bundle Component Relationship.\n\n        If you donʼt see it, you must manually create it by navigating to App Launcher → Product Relationship Types → New, and setting the following options:\n\n        -   Product Relationship Type Name: “Bundle to Bundle Component Relationship”\n        -   Associated Product Role Category: “Bundle Component”\n        -   Main Product Role Category: “Bundle Parent”\n9.  Create a new Attribute Category \\(App Launcher → Product Catalog Management → Attribute Categories\\) with the following options:\n    -   Name: “Server Rack Specifications”\n    -   Code: “SPEC”\n    -   Description: “Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.\"\n10. Create a new Attribute Definition \\(App Launcher → Product Catalog Management → Attributes\\) with the following options:\n    -   Name: “Load Capacity”\n    -   Label: “Load Capacity”\n    -   API Name: “LoadCapacity”\n    -   Data Type: “Number”\n    -   Default Value: 1500\n    -   Active: true\n    -   Code: “CAP”\n    -   Description: \"Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.\"\n11. Return to the related list of the new \"Server Rack Specifications\" attribute category you created, and in its related list, under \"Attributes\", click \"Assign\" and add the \"Load Capacity\" attribute to it.\n12. App Launcher → Product Catalog Management → Product Classifications → \"Server Racks\" → \"Attributes\" tab: Click \"Assign\" → \"Assign individual attributes\" → add the \"Load Capacity\" attribute.\n\n    \\[Omitted image \"cpq-logik-config-for-sf-rlm-38.png\"\\] Alt text: Load capacity screen\n\n    \\[Omitted image \"cpq-logik-config-for-sf-rlm-39.png\"\\] Alt text: Service rack specification\n\n    \\[Omitted image \"cpq-logik-config-for-sf-rlm-40.png\"\\] Alt text: Server racks\n\n    \\[Omitted image \"cpq-logik-config-for-sf-rlm-41.png\"\\] Alt text: Price book entry\n\n\n## Salesforce Transaction Line Editor Setup\n\nA Lightning Web Component is available to perform configure/reconfigure and view the Quote Line Items in their bundled/hierarchical view. To add this component to the layout:\n\n1.  App Launcher → Sales → Quotes → open a quote.\n2.  Press the gear icon on the top-right corner of the page and select \"Edit Page\".\n\n    \\[Omitted image \"cpq-edit-page.png\"\\] Alt text: Salesforce Transaction Line Editor Setup\n\n3.  From left menu, drag Transaction Line Editor component onto the layout.\n\n    \\[Omitted image \"cpq-transaction-line-editor.png\"\\] Alt text: Transaction components\n\n4.  Save and Activate.\n\n## Salesforce Product Configuration Flows Setup\n\nInstead of assigning a Configurator at the org level, a new object determines which configurator to launch per product.\n\n1.  Search for and open the sObject, \"Product Configuration Flow\"\n2.  Create a new Config Flow record and set the Flow Identifier as \"RLMConfiguratorScreen\". If you're only using one configurator, make this the Default as well.\n\nIf there are multiple config flows being used, the flow can be assigned to individual products or product classifications through the Related records.\n\n\\[Omitted image \"cpq-product-configuration-flows.png\"\\] Alt text: SMC configuration\n\n## Salesforce Product Discovery Setup\n\nConfigure from Quote: With Product Discovery, products can be configured before being added as a quote line.\n\n1.  App Launcher → Sales → Quotes → open a quote.\n2.  Press the gear icon on the top-right corner of the page and select \"Edit Object\".\n3.  Go to Page Layouts; for the layouts being used, add the “Browse Catalog” action to the layout and save.\n\n\\[Omitted image \"cpq-edit-object.png\"\\] Alt text: Setup menu\n\nConfigure from account is not currently supported. In the future, the user will be able to configure without reference to a quote. For instance, this could be used to launch product discovery from the account page.\n\n1.  From a Catalog page, open the Admin gears and click “Edit Page”.\n2.  Under Components, search for and add the \"Product List Page Component\" onto the page.\n\n    \\[Omitted image \"cpq-logik-config-for-sf-rlm-46.png\"\\] Alt text: Product list components\n\n3.  Save, and if needed, Activate and assign as default.\n\n## CPQ Webhook Setup\n\n1.  If Webhooks are not enabled on your CPQ environment, create a Support case and request Webhooks be turned on in the environment.\n\n    To create a support case, use the [ServiceNow Support portal](https://support.servicenow.com). For step-by-step instructions, see [Create a case on Now Support for CPQ Customers](https://support.servicenow.com/kb?sys_kb_id=d67d3e71475d7a90f64de825126d4326&id=kb_article_view).\n\n2.  When Webhooks are enabled, navigate to CPQ Admin Home → Utilities → Webhooks, and create a new Webhook with the following settings:\n\n    -   Integration Type: Salesforce\n    -   Async: false\n    -   Content: Either \"All\" or \"BOM and System Fields\"\n    -   BOM Types: \"sales\" \\(others can optionally be added, but \"sales\" is required\\)\n    \\[Omitted image \"cpq-webhook-setup.png\"\\] Alt text: Webhook screen\n\n\n## CPQ Product Selling Models Setup\n\nIn a product action, pricing fields for Revenue Lifecycle Management can be set, similar to extended info. These are available in both simple and advanced product actions.\n\nExample of simple product action setup:\n\n\\[Omitted image \"cpq-product-selling-models-setup.png\"\\] Alt text: Product selling models setup\n\nAvailable pricing map \\(ProductList.pricing\\) fields are:\n\n-   productSellingModelId\n-   startDate\n-   endDate\n\nAssuming Product Selling Models have been created in Salesforce, the productSellingModelId can be found in a subpage of Utilities and will automatically be suggested in the simple product action UI.\n\nExample productSellingModelId based on this image would be \"Term\\_Defined\\_TermDefined\\_1\\_Months\\_2023\\_03\\_02\"\n\n\\[Omitted image \"cpq-product-selling-models-setup-example.png\"\\] Alt text: Product Selling models\n\n## Salesforce: Enable Context Service\n\n1.  Setup → Feature Settings → Context Service → Context Service Settings: Set “Context Definitions” to \"On\"\n2.  Refresh the page. If you donʼt see the next step, wait 10 seconds and try again.\n\n    If you still donʼt see the next step, wait 20 seconds and try again. This is an asynchronous process.\n\n3.  Setup → Feature Settings → Context Service → Context Definitions: Confirm that under “Standard Definitions”, the “Sales Transaction Context” is present and is “Active”.\n    1.  Open dropdown menu for \"SalesTransactionContext\\_\\_stdctx\" and press 'Extend'.\n    2.  Populate the new Context Definition and Save.\n    3.  Go to the Custom Definitions tab. Open the dropdown menu for the newly created Context Definition and press 'Activate'.\n\n\\[Omitted image \"cpq-enable-context-service.png\"\\] Alt text: Context definitions\n\n## Salesforce: Enable Business Rules Engine \\(BRE\\) for Qualification\n\n1.  Setup → Feature Settings → Business Rules Engine → Business Rules Engine Settings: Toggle on the switch to enable “Industries Cloud Common Decision Tables Access”\n2.  Setup → Context Service → Context Definition: Create a new custom context definition named “BrowseContextdefinition” \\(this name must match exactly\\). Don't set any other fields.\n3.  Click “Next”\n4.  Add the following context nodes:\n    -   Name: “PriceBook”\n    -   Name: “Account”\n    -   Name: “Catalog”\n5.  Under “Catalog”, add a child node of ”Category“\n6.  Under “Category”, add child nodes of “CategoryProduct” and “PricingProduct”\n7.  Under “CategoryProduct” add a child node of “Message”, and click Next.\n8.  Under “PriceBook”, click “Add Attributes” and add the PricebookID attribute:\n    -   AttributeName: “PricebookId”\n    -   Type: “INPUT”\n    -   Data Type: “STRING”\n9.  Under “Account”, click “Add Attributes” and add attributes with the following AttributeNames, a type of INPUT, and a data type of STRING:\n    -   Id\n    -   contactId\n    -   AccountCity\\_\\_c\n    -   SLA\\_\\_c\n    -   CurrencyIsoCode\n    -   Region\\_\\_c\n10. Under “Catalog”, click “Add Attributes” and add attributes with the following AttributeNames, a type of INPUT, and a data type of STRING:\n    -   Id\n    -   CurrentDate\n11. Under “Category”, click “Add Attributes” and add the following attributes with a data type of STRING and the type as specified:\n    -   CategoryId \\(Type: INPUT\\)\n    -   IsCategoryQualified \\(Type: OUTPUT\\)\n    -   CategoryDisqualifiedReason \\(Type: OUTPUT\\)\n12. Under \"CategoryProduct\", click \"Add Attributes\" and add attributes with the following AttributeNames, a type of INPUT, and a data type of STRING, unless otherwise specified:\n    -   Id\n    -   ProductId\n    -   RootProductId\n    -   ParentProductId\n    -   CategoryId\n    -   CatalogId\n    -   Name\n    -   Code\n    -   MaxQuantity \\(Data Type: NUMBER\\)\n    -   MinQuantity \\(Data Type: NUMBER\\)\n    -   Quantity \\(Data Type: NUMBER\\)\n    -   IsQualified \\(Type: OUTPUT; Data Type: NUMBER\\)\n    -   Reason \\(Type: Output: Data Type: STRING\\)\n13. Under \"Message\", click \"Add Attributes\" and add the following attributes with a type of OUTPUT and a data type of STRING:\n    -   Name\n    -   Value\n14. Under \"PricingProduct\", click \"Add Attributes\" and add the following attributes:\n    -   PricingId\n        -   Type: INPUT\n        -   Data Type: STRING\n    -   PricingProductId\n        -   Type: INPUT\n        -   Data Type: STRING\n    -   ProductSellingModelId\n        -   Type: INPUT\n        -   Data Type: STRING\n    -   ProductQuantity\n        -   Type: INPUT\n        -   Data Type: NUMBER\n    -   UnitPrice\n        -   Type: OUTPUT\n        -   Data Type: CURRENCY\n    -   NetUnitPrice\n        -   Type: OUTPUT\n        -   Data Type: CURRENCY\n    -   PriceWaterFall\n        -   Type: OUTPUT\n        -   Data Type: STRING\n    -   PricingErrorMessage\n        -   Type: OUTPUT\n        -   Data Type: STRING\n15. Click Next.\n16. For each of the following nodes, add node tags that exactly match the name of the node:\n    -   PriceBook\n    -   Account\n    -   Catalog\n    -   Category\n    -   CategoryProduct\n    -   PricingProduct\n17. For each of the following attributes, add the specified attribute tags:\n    -   \\(For PriceBook:\\) PriceBookId: PriceBookId\n    -   For Account:\n        -   AccountCity\\_c: AccountCity\n        -   SLA\\_c: SLA\n        -   CurrencyIsoCode: CurrencyCode\n    -   \\(For Catalog:\\) CurrentDate: CurrentDate\n    -   For Category, give each attribute a tag that exactly matches the name:\n        -   CategoryId\n        -   IsCategoryQualified\n        -   CategoryDisqualifiedReason\n    -   For CategoryProduct, give each attribute a tag that exactly matches the name:\n        -   ProductId\n        -   RootProductId\n        -   ParentProductId\n        -   IsQualified\n        -   Reason\n    -   For PricingProduct, give each attribute a tag that exactly matches the name:\n\n        -   PricingProductId\n        -   ProductSellingModeId\n        -   ProductQuantity\n        -   PricingId\n        -   UnitPrice\n        -   NetUnitPrice\n        -   PricingErrorMessage\n        For PriceWaterFall, assign a tag of price\\_water\\_fall. Click Save.\n\n18. Open your newly created \"BrowseContextDefinition\" → click \"Map Data\" tab → click \"Add Mapping\":\n    -   Mapping Name: \"BrowseOperation\"\n    -   Description: \"Browse Operation\"\n    -   Mapping Type \\(select both\\):\n        -   \"Automatic Input Schema Mapping\"\n        -   \"Automatic sObject Mapping\"\n    -   Mark as Default: TRUE\n19. Setup → Context Service → Context Definitions: in \"BrowseContextDefinition\" menu, click \"Activate\"\n20. App Launcher → Business Rules Engine → Lookup Tables: Click “New” and select “Decision Table”\n\n    -   Name: “ProductQualificationDT”\n    -   Description: “Qualification Rules decision table”\n    -   API Name: “ProductQualificationDT”\n    -   Source Object: “Product Qualification”\n    -   Filter Result By: “Any Value”\n    -   Usage Type: “Product Qualification”\n    On the next screen, because weʼre going for the simplest qualification rule, we have only a single input and output \\(i.e. “Given a Product ID, tell me if its qualified or not”\\)\n\n21. Next to “ProductId” set “Donʼt Use” to “Optional input”\n22. Next to “IsQualified” set “Donʼt Use” to “Output”\n23. Click “Next” and “Save\"\n24. Click the “Activate” button in the upper right corner to activate the decision table\n25. App Launcher → Business Rules Engine → Expression Sets: Click \"New\" to create a new Expression Set\n    -   Name: “QualificationProcedure”\n    -   Usage Type: “Product Qualification\"\n    -   Context Definition: “BrowseContextdefinition”\n26. In the newly created expression set record home, see the “Expression Set Versions” table and click the first row to launch the Expression Set Builder.\n27. In the expression set builder, click the “+” button in the middle of the screen and select “Evaluate Qualification”\n    -   Lookup Table Details: “ProductQualificationDT”\n    -   ProductId: “ProductId”\n    -   IsQualified: “IsQualified”\n    -   Reason: “Reason”\n28. In the sidebar in the expression set builder, click the cog icon and set the “Rank” equal to 1\n29. Click the Element Details tab and select “Include in Output”\n30. Click “Save As”, wait for the full-page refresh, and then click “Activate”\n\n    At this point, your BRE Qualification Rules should be setup correctly. To end, we will simulate the configuration to verify that it is working correctly.\n\n31. In the Expression Set Editor, click the “Simulate button”\n32. Select “Advanced” for the input and populate the ProductId field with your Cisco Server Rack NX44 product ID\n\n    Leave the IsQualified and Reason fields as empty strings.\n\n33. Click “Simulate”\n\nInspect the Output JSON to see if your product returns. \"IsQualified\" will be \"null\" and \"Reason\" will be an empty string.\n\n## Salesforce: Pricing Procedure\n\n1.  App Launcher → search for and open \"Pricing Procedures\" → open the \"Revenue Management Default Pricing Procedure\" → open the active Pricing Procedure and deactivate it.\n2.  Return to the Revenue Management Default Pricing Procedure. Edit it.\n\n    Change the Context Definition to the custom definition that was extended from \"SalesTransactionContext\\_\\_stdctx\". Save.\n\n3.  Reactivate the Pricing Procedure Version.\n\n## Troubleshooting\n\nIssue: The CPQ blueprint was loaded into the RLM org, but no products show in the product catalog during quoting.\n\nDiagnosis: This could mean that there's an issue with the Product Discovery settings \\(see the [Salesforce: Enable Context Service](https://docs.google.com/document/d/10MqNVlW4X5ikoLvYTH3NeBhQO7mDq6rUUt3bsP428Ig/edit#heading%3Dh.t6hdyrii25c4) section and beyond\\).\n\n-   Setup → Feature Settings → Decision Tables. Open both the ProductQualification and Price Book Entries tables and perform the 'Refresh' action on each.\n-   If the refresh doesn't solved the problem, view the following Salesforce documentation:\n    -   [RLM Product](https://help.salesforce.com/s/articleView?id=sf.qocal_product_discovery_setup.htm&type=5)\n    -   [Discovery Setup](https://help.salesforce.com/s/articleView?id=sf.qocal_product_discovery_setup.htm&type=5)\n\nIssue: At runtime, the user receives the following error in RLM: `System.IllegalArgumentException: Looks like you don't have access to the place quote service. Salesforce Customer Support can help with that`\n\nDiagnosis: This is a permission set issue. Make sure that the following three RLM permission sets are assigned to the integration user that facilitates the CPQ integration.\n\n-   Product Catalog Management Designer\n-   ProductAndPriceConfiguration API\n-   Product Catalog Management Viewer\n\n"}}