Welcome to Zuora Product Documentation

Explore our rich library of product information

Build the rule

Learn how to configure a feature rule in the Admin console by following a series of steps, including adding JavaScript to a site and creating a basic rule to test integration.

When you have added the JavaScript to a site, as shown in the example page, you can configure a feature rule.

To configure a feature rule in the Admin console, complete the following steps:

  1. Select Products > Features from the main menu.
  2. Select the Add a Feature button . The Add a Feature screen displays.
  3. Enter the following details:
    1. Enter a name for the feature in the Title text box.
    2. Optionally, add a description of the feature, using no more than 100 characters, in the Description text box.
    3. Select the HTML radio button from the Types of Integration option.
    4. Select the Continue button to create the feature.
  4. Complete the Developer Interface section to configure the type of integration as follows:
    1. Select the Run In Browser radio button from the Where to Run option.
    2. Enter a CSS Selector for the feature in the CSS Selector text box.
    3. Define JSON paths that could be used to make decisions in the rule. The JSON paths should match the JSON object that is passed as custom data. Click Add A JSON Path to add a JSON path. Available data types are String, Number, Boolean, and DateTime. You can later create Custom Data decisions based on the JSON Path defined here.
    4. Select the Update & Lock button. Selecting the Cancel button closes and locks the Developer Interface without making changes.
      Note: If you return to an existing feature, the Developer Interface section is locked by default and located at the bottom of the page. You can unlock and open the Developer Interface section by clicking inside the border. The rules canvas section displays.
  5. Create a basic rule to test the integration as follows: Your new outcome is added to the palette, with the title you entered.
    1. By default, the Anonymous user journey is selected, select Outcomes from the decision bar.
    2. Select Add Outcome from the listed decision points. The Add an Outcome screen displays.
    3. Enter a name for your Outcome in the Title text box.
    4. Optionally, add a description of the outcome in the Description text box.
    5. Select the Add a New Form Or Custom Component Block button.
    6. Select the Add Custom Component Block button. The Custom Content Block dialog box displays.
    7. Enter a name for the custom content block in the Title text box.
    8. Enter a message in the large text box.
    9. Select the Save button. The Add an Outcome screen displays.
    10. Select the Save button to save your outcome.
  6. Drag your outcome to the rules canvas.
  7. Connect your outcome to the Page View node.
  8. Scroll to the bottom of the screen and select the up arrow next to the Save button.
  9. Select Save and Publish .