Welcome to Zuora Product Documentation

Explore our rich library of product information

Create a name check sub rule

Create a sub rule to prompt registered users to provide their first name if it is not already available, using a data capture form outcome.

When a registered user has viewed two pieces of content but has not yet provided their first name, we want to prompt them to share it. To achieve this, we'll create a data capture form outcome. In this example, we'll use a sub rule that checks whether the registered user's first name is already available and displays the form if it isn't.
Note:

Sub rules are especially useful for managing complex journeys. For more details, see the Simplify User Journeys with Sub Rules section.

To build the data capture form in a sub rule, complete the following steps:

  1. If necessary, navigate to the feature we used for our Anonymous and Registered user types as follows:
    1. Navigate to Products > Features from the main menu.
    2. Select the Article feature.
    3. Select the version to update. The rules builder displays.
  2. Select the circle beneath Registered in the user type selector bar. A blank canvas displays.
  3. Add a sub rule, as follows:
    1. Select the Sub Rules segment title from the decision bar.
    2. Drag the Sub Rule outcome to the rules canvas. The Sub Rule dialog box displays.
    3. Enter Name Check in the Title text box.
    4. Select the Save button. A blank sub rule canvas displays.
  4. Select the User segment title from the decision bar.
  5. Drag the User Attribute decision node to the sub rule canvas. The User Attribute dialog box displays. Complete this dialog box as follows:
    1. Select First Name (Text) from the User Attribute menu. A further field displays.
    2. Select Is Empty from the Condition menu.
    3. Select the Save button. The User Attribute decision node is added to your sub rule canvas. For further information on the User Attribute decision node, see the User topic.
  6. Add an output option for registered users that have already supplied their first name as follows:
    1. Select the Sub Rules segment title from the decision bar.
    2. Drag the Output Option decision node to your sub rule canvas. The Output Option dialog box displays.
    3. Enter Name Provided in the Title text box.
    4. Select the Save button. The output option is added to your sub rule canvas.
  7. Add a data capture form outcome to collect the first name from registered users that have not supplied their first name as follows: The outcome is added to your sub rule canvas.
    1. Select the Outcome segment title from the decision bar.
    2. Select Add Outcome . The Add an Outcome screen displays.
    3. Enter Data Capture Form in the Title text box.
    4. Select the Add A New Form Or Custom Component Block button.
    5. Select the Add button under the Form heading.
    6. Select the Data Capture radio button under the Type options. The Title text box is pre-filled with Data Capture Form. You can edit this if required.
    7. Select the Add A User Attribute button. The Add a User Attribute dialog box displays.
    8. Select the Add button at the end of the First Name row. The First Name user attribute is added to your form.
    9. Select the Required toggle.
    10. Select the Save button. The Edit an Outcome screen displays.
    11. Select the Save button. Your Data Capture Form outcome is added to the decision bar.
  8. Drag the Data Capture Form outcome to your sub rule canvas.
  9. Connect your sub rule as follows:
    1. Drag from the white circle under the Start Sub Rule node to the Is Empty User Attribute decision node.
    2. Drag the Yes node from the User Attribute decision node to the Data Capture Form outcome.
    3. Drag the No node to the Name Provided output option. Your rule looks similar to the following: IncDataEg_Reg_SubRule.jpg
    4. Select the Done button to return to the main rules canvas.
      Your sub rule displays in your main rule as a pink box with a Name Provided node that you can connect to the rest of your rule.
      We continue building the rule with a further trial. To do this, we can follow the instructions in the Create Your Trial topic from the end-to-end example.
      Note: As we now have two trials on the Registered canvas, by default both use the Article default registered tracker. If you want to use different consumption trackers for these trials, select the Consumption Tracker button and define the tracker you want to use, as described in the Access topic.
      After we have added the further trial, we build a paywall to allow registered users to subscribe to a product and become a customer. To do this, follow the instructions in the Create Your Payment Form Outcome from the end-to-end example.