Validate notification template conditions
You can validate each notification template condition against a corresponding notification type's parameter example to ensure that it is valid and suitable for use by the v2 notification system. The validation operation compares the filter's user-defined combination of parameter, operator, and value against the predefined parameter example associated with the selected template type. You can also edit the parameter example to test additional scenarios.
You can validate the filter with the following procedure when you create new filters or when you edit or test existing filters. For information about creating filters, see Create notification templates and conditions
To validate an existing notification filter
📝 Note: If the AppDirect logo appears in the upper-left corner of the page, when Manage > Marketplace appears in this topic, click the grid icon > Switch to | Store, instead.
- Locate the notification template that contains the filter you want to validate.
- Go to Manage > Marketplace > Settings > Custom UI | Notifications. The Notifications page opens.
- Click the gear icon > Edit next to the notification type for which you want to validate a notification filter. The {notification type} page appears for the selected notification type. It displays the Default template on the Email tab.
- (Optional) Click one of the other delivery method tabs: SMS or Off platform. The Default template appears for the selected delivery method.
- Select the template that contains the filter from the unlabeled template drop-down list (it displays Default when the page is first loaded).
- In the Filters table, click the gear icon > Edit Filter next to the filter that you want to validate. The Configure Filter dialog appears.
- Click Show advanced features. The following validation elements appear in the dialog:
- Validate Filter button
- Validation Results (displays Unverified by default)
- Default parameter values associated with the selected notification type (you can validate against the default content of the parameter example, or you can edit it to test additional scenarios)
- Click Validate Filter. One of the following validation results appears:
- True—The combination of parameter, operator, and value matches the schema. The conditions defined in this filter and the associated template are valid for the parameters defined in the template type's parameter example. This operation does not validate any other filters associated with this template.
- False—A message indicates that the validation failed. Note the following about False results:
- The validation operation is case sensitive. For example, acme does not match Acme and causes the validation to fail.
- You can still save this filter, but be aware that it does not validate against the schema.
- Do one or more of the following as appropriate:
- If the filter evaluated to True:
- Edit one or more of Parameter, Operator, or Value fields, then validate it against the existing parameter example again.
- Edit the parameter example to test another scenario (this does not alter the master version of the example, only the temporary version displayed here for validation purposes). For example, if you successfully validated an order against the default
"editionName": "Silver"
, you could edit theeditionName
toGold
(or any other valid edition name), and validate a different order scenario as follows:
"orders": [
{
"type": "ITEM",
"applicationName": "Office 365",
"editionName": "Gold",
"perUnitPrice": 25,
"unitQuantity": 1,
"totalCost": 25
}- Click Save if you made any changes to the filter. The template that contains the filter appears.
- If the filter evaluated to False:
- Edit the parameter example (this does not alter the master version of the example, only the temporary version displayed here for validation purposes).
- Edit one or more of Parameter, Operator, or Value fields, then validate against the existing parameter example again.
- Click Save if you made any changes to the filter that you want to save even if this filter did not validate against the parameter example.
- If the filter evaluated to True:
Was this page helpful?
Tell us more…
Help us improve our content. Responses are anonymous.
Thanks
We appreciate your feedback!