Prerequisites

  • Ensure that all survey names, schedule names, event names, group type names, and group name fields are named correctly.
  • Ensure that the survey and schedule are already created. See Configuring Surveys for more information.

Create a Rule Template

Complete the following steps to create a rule template:

  1. In eCOA Studio, open the Rules tab.
  2. Select Create Rule.
  3. In the Rule Templates dialog box, select Survey-based Notification and select Select Template. A new rule template for survey-based notifications opens.
  4. Enter a name for the rule in the Name field. For example: Rule_1
  5. Enter a description of what the rule is for in the Description field to help other Studio users identify what the rule is when they see it in the Rules tab. For example: This rule enables you to receive notifications when a user answers certain questions on a survey.
  6. Create a reference for the survey or survey part that should trigger the rule evaluation. A rule triggered by a specific part can only reference data from that part. When the reference survey conditions are met, the system will automatically evaluate the expression provided in the rule template. For example: $survey.hads.[*].[*].[*] See Creating a Reference on the Understanding Rules page for more information.
Tip: Enter $ or @ to begin, and then select from the options that are displayed. Use the $survey identifier to reference a survey where all parts are complete or missed. Use the $surveyPart identifier to reference a specific completed part, even if other parts are incomplete. After you select each option, enter a period and select from the next list of options that are displayed.
  1. Optionally, define the precondition using references or variables, and add the data you want to evaluate. For example: @survey.hads.[*].[*].[-1].status = "COMPLIANT" - In this example, adding the following precondition ensures that a rule only runs when the most recent submitted survey is compliant. See Creating a Reference and Creating a Variable on the Understanding Rules page for more information.
  1. Using Vault expression engine syntax, create an expression that evaluates to TRUE or FALSE. Only references that evaluate to TRUE will cause the action to run. See Creating an Expression for more information. For example: IF((Q1ANS = "3") || (Q2ANS = "3"), true, false)
  1. Enter a name in the Notification Name field. Example: hads_notification_1
  2. Select Site Staff or Email Address from the recipient list. If you selected Site Staff, continue to Step 11. If you selected Email Address, skip to Step 12.
  3. Select all roles you want to receive the notification from the Role Type list. Skip to Step 14.
  4. In the Email Address(es) field, enter the email address of a person you want to receive notifications, and press ENTER. You can add multiple emails.
Tip: As a best practice Veeva recommends using a listserv email addresses instead of individual emails so you can update email recipients without creating a new collection version.
  1. In the Testing Email field, enter the email address you want to use during UAT. When in UAT, this email address will receive any rule-triggered emails instead of the addresses listed in the Email field. For example: test.person@veeva.com
  1. Enter the title you want to be displayed with the notification in the Title field. For example: <b>Survey answer exceeds threshold for {{studyName}}</b>
  2. Enter the body message of the notification in the Body field. For example: The HADS response for <b>{{participantID}}</b> in <u>{{studyName}}</u> has answered a question with a response that requires additional attention. See <a href="https://www.Veeva.com">Veeva.com</a> for more information.
  3. To prevent users who do not have permission from seeing restricted data, select the Yes option under Restricted Data.
  1. Select Save.
  2. Select Add Another and repeat Steps 9 through 17 to add additional notifications.
  3. Select Save & Exit.

Using Available Tokens

Use these tokens to add dynamic information about what information triggered the notification:

Information Type Description Token
Participant ID The ID of the participant who completed the survey. {{participantID}}
Participant ID (Linked)
  • The ID of the participant who completed the survey.
  • Linked to the participant profile.
  • Can only be used in the notification body.
  • Must use three curly braces for the hyperlink to be displayed correctly.
{{{participantIDLink}}}
Site ID The study site number. {{siteID}}
Site Name The study site name. {{siteName}}
Study Name The study name. {{studyName}}
Survey Label
  • The survey label for the survey.
  • If available, the translated value is displayed for site notifications. Dynamic information cannot be translated for email notifications, so they are displayed in English.
{{surveyLabel}}
Survey Label (Linked)
  • The survey label for the survey.
  • Linked to the completed triggering survey.
  • Can only be used in the notification body.
  • If available, the translated value is displayed for site notifications. Dynamic information cannot be translated for email notifications, so they are displayed in English.
  • Must use three curly braces for the hyperlink to be displayed correctly.
{{{surveyLabelLink}}}
Survey Schedule The schedule name for the survey. {{surveySchedule}}

Adding a Token

  1. Select the Tools button.
  2. Select the Template Tokens tab.
  3. Select Copy next to the token. The text is copied to your clipboard.
  4. Paste the token into the Title or Body field.

The token is added to the title or body where you pasted it.

Saving a Rule

Draft template changes are automatically saved as you make updates. If you sign out and back in, when you access the templates, you can continue working on your draft. If you choose to create a new draft before manually saving an in-progress draft, your changes will be lost.

You can save a rule by selecting the Save button.

Editing a Rule

You can edit a rule when the collection is in a Draft state.

Complete the following steps to edit a rule:

  1. Open the collection, select the Rules tab, and select the Edit Rule icon (Edit Rule icon) next to the rules you want to edit.
  2. Make any changes you want to see, and select Save. Your changes are saved.

Deleting a Rule

You can only delete rules that have not been included in an approved collection. Once a rule is deleted, it cannot be recovered.

Complete the following steps to delete a rule:

  1. Open the collection, select the Rules tab, and select the Delete Rule icon (Delete icon) next to the rule you want to delete. A confirmation box opens.
  2. Select Delete. The rule is deleted.