Understand general set up for Oracle CPQ

Some general set up procedures for Oracle CPQ need to be completed for the integration to run successfully.

You must complete the following Oracle CPQ general set up procedures:

  • Enable Guest Access to Oracle CPQ
  • Add Template Dependencies to File Manger
  • Make Oracle CPQ Stylesheet Edits
  • Synchronize Oracle CPQ Parts with Commerce SKUs

Enable Guest Access to Oracle CPQ

Administrators can allow multiple self-service users in Commerce to access an Oracle CPQ site as a guest user from an iFrame displaying within Commerce. When Commerce punches in to Oracle CPQ for configuring items, the system uses sessions for unregistered users (i.e. guest users). When self-service users access an Oracle CPQ site, their session parameters pass from Commerce to Oracle CPQ. This provides a seamless user experience and eliminates the need for Commerce self-service users to enter login credentials when entering an Oracle CPQ site from Commerce.

Note: You can now customize the configurations of complex products in Commerce without being redirected to an Oracle CPQ hosted iFrame. This capability, known as the Direct API Configuration feature, builds out support in Commerce for direct API driven product configurations where the user interface experience is controlled instead by Commerce and can be customized by Commerce partners rather than relying on the Oracle CPQ hosted iFrame. Refer to the Using Oracle CPQ Features with Oracle CX Commerce guide in the Oracle CX Commerce Doc Library for complete details.

Session parameters include currency, language, and locale preferences such as number format, units, and date format. For example: If a Commerce self-service user’s language preference is set to German, the text in the Oracle CPQ interface displays in German when the user accesses Oracle CPQ. The user’s currency and locale preferences are also passed from Commerce and display in Oracle CPQ.

To enable guest access to Oracle CPQ:

  1. Open the Admin Home page.
  2. Under General, select General Site Options. The Options – General page opens.
  3. Under Options – Login, set Allow Guest Access to Yes.

    This setting allows Commerce to punch in to Oracle CPQ.

  4. If multi-currency support from Commerce is required, set Allow Direct Login [Deprecated: Please use SSO feature] to Yes. login
  5. Under Options – General, set Occupy entire window when the site is inside a frame to No. This setting improves usability when punching in to Oracle CPQ from Commerce. General Options screenshot

Add Template Dependencies to File Manager

The “Add to Cart” action sends items to a Commerce cart via an Add to Cart button, which displays on the Commerce integrated Oracle CPQ site following configuration. Use the information provided in this section to add payload template files to File Manager. If Commerce requires additional information from Oracle CPQ during the “Add to Cart” action, administrators can add the information by creating configurable attributes and modifying the payload templates. Administrators can then export the configurable attributes as key-value pairs from Oracle CPQ to Commerce.

Payload template files (i.e. Recommended_Items_Payload-Cloud.txt and AddToCartPayload-Cloud.txt) form the payload structure for sending a configured item to the Commerce shopping cart. The template files support the “Add to Cart” action and include configuration information such as config id, quantity, and BOM items. BML reads the template files and replaces the values in brackets, such as {{bomitems}}, with dynamic values.

Complete the following steps to add the payload template files to File Manager:

  1. Open the Admin Home page.
  2. Navigate to Utilities > File Manager. File Manager opens.
  3. Create a new folder named CommerceCloud.
  4. Under Add Files, click Browse. The Choose File to Upload dialog opens.
  5. Navigate to the Recommended_Items_Payload-Cloud.txt file and click Open.
  6. Click Add File. The Recommended_Items_Payload-Cloud.txt file displays in File Manager.
  7. Complete steps 1-6 for AddToCartPayload-Cloud.txt.

Shown below is the content of each of the payload template files.

Recommended_Items_Payload-Cloud.txt

{
 "quantity": "{{quantity}}",
 "catalogRefId": "{{part}}",
 "price": "{{price}}",
 "recurringCharge": { "amount":"{{recurringPrice}}",
 "frequency":"{{pricePeriod}}",
 "duration":"{{duration}}" }
} 

AddToCartPayload-Cloud.txt

{
 "messageType": "Configuration_Details",
 "quantity": "1",
 "catalogRefId": "{{model}}",
 "amount": "{{totalPrice}}",
 "price": "{{basePrice}}",
 "currencyCode": "{{currency}}",
 "configurationId": "{{ConfigId}}",
 "childItems": [{{ChildItems}}],
 "bomItems": [{{BomItems}}]
}

Make Oracle CPQ Stylesheet Edits

Oracle recommends administrators hide Oracle CPQ navigation options outside the scope of the integration from Commerce self-service users.

Hide the Oracle CPQ Home Button

By hiding the Oracle CPQ Home button, the Oracle CPQ configurator opens whenever users access Oracle CPQ. Users cannot navigate away from the original model that opens in the configurator, which prevents them from configuring a different model or adding a different model to Commerce.

To hide the Oracle CPQ Home button:

  1. Open the Admin Home page.
  2. Under Style and Templates, select Stylesheet. The Stylesheet Manager page opens.
  3. Select Download Alternate Stylesheet next to Click to Download Alternate CSS from the CSS Upload/Download Center.stylesheet manager screen shot
  4. When the alternate CSS file opens, update the CSS to include the following CSS snippet to hide the Home button within the iFrame.
    
    .nav-links>a img[title="Home"]{
        display: none;
    }
    

Note: If the Home button shows both a label and an icon, administrators cannot hide the label using only CSS. From the Admin Home page, navigate to Style and Templates > Navigation Menus > Subheader > Home > Edit. Choose Icon for Display. The Home button is then hidden with the CSS change.

Hide Price Books

Oracle CPQ uses PriceBooks as a way to associate parts with a price. Oracle recommends hiding Price Book information from users.

To hide Price Books:

  1. Open the Admin Home page.
  2. Under Products, select Catalog Definition.The Supported Products page opens.
  3. From the Navigation drop-down menu, select Stylesheets.
  4. Click List. The RegularStylesheets List page opens.
  5. Download the DefaultRegular Stylesheet.Screenshot of regular stylesheet
  6. Copy the contents of the DefaultRegular Stylesheet.
  7. Create a new stylesheet with a name indicative of the stylesheet’s purpose. For example: Hide Price Books
  8. Paste the contents of the Default Regular Stylesheet into the new stylesheet and add the following CSS:
       
    .pricebook-container {
               display:
              none;   
    }
  9. Save the stylesheet.
  10. On the Regular Stylesheets List page, click Add Alternate. The Configuration Stylesheet Editor opens.
  11. Click Browse.
  12. Use the File Upload dialog to locate and select the new stylesheet.
  13. Click Open. The stylesheet displays in the Regular Stylesheets List page under the list of Alternate Stylesheets.

Synchronize Oracle CPQ Parts with Commerce SKUs

In Commerce, SKUs represent a purchasable instance of a product on a Commerce storefront. Administrators must synchronize Oracle CPQ parts with Commerce SKUs to ensure the pricing information associated with a part is the same in both Oracle CPQ and Commerce.

To synchronize Oracle CPQ parts with Commerce SKUs:

  1. Open the Admin Home page.
  2. Under Products, select Parts. The Part Administration page opens.
  3. Add new parts in Oracle CPQ with part numbers that match SKUs in Commerce.
  4. Add Part Custom fields for recurring charge price type, frequency, duration, and cost.
Notes:
  • The client-side BML sample included in the Configure Client-Side Integration, Add To Cart Button, and JSON Response section of this implementation guide assumes part custom fields 4, 5, 6, and 8 represent recurring period, cost, duration, and type respectively. In order to use other part custom fields, the Add to Cart BML and OIC mappings will have to be adjusted accordingly.
  • If a non-configurable SKU is later added to Commerce and intended for use by the Oracle CX Commerce and Oracle CPQ integration, repeat the above procedure to add the corresponding part in Oracle CPQ.
  • In addition toOracle CPQ parts, configurable models must also have a corresponding SKU in Commerce. The SKU number in Commerce should match the model’s label and variable name.