Emails sent to users can be customized using templates defined at the site level. A subset can also be customized at the project or folder level.

Email Templates

  • Select (Admin) > Site > Admin Console.
  • Click the Admin Console Links tab.
  • Under Configuration, click Email Customization.
  • Select an Email Type from the pulldown to customize the templates. Available template types (not all are shown in all server configurations:
    • Change email address: The administrator also receives this notification.
    • Register new user (with or without a bcc to admin)
    • Request email address: The administrator also receives this notification.
    • Reset password (with or without a bcc to admin)
    • Issue update
    • Pipeline jobs succeeded (digest form optional)
    • Pipeline jobs failed (digest form optional)
    • Message board notification
    • Message board daily digest
    • Report/dataset change (digest)
    • Specimen request notification
    • Audit Processing Failure: See Compliance: User Accounts and Login.

For your server to be able to send email, you also need to configure SMTP settings in your labkey.xml file. See SMTP Settings for more information. To test these settings:
  • Select (Admin) > Site > Admin Console.
  • Click the Admin Console Links tab.
  • Under Diagnostics, click Test Email Configuration.

Template Customization

To customize the template, complete the fields:

  • From Name: The display name for the sender, typically the short site name. The email "From" field will be populated with the one configured via site or project settings.
  • Reply To Email: If you prefer a different "Reply-To" address, supply it here.
  • Subject
  • Message

Substitution Strings

Message template fields can contain a mix of static text and substitution parameters. A substitution parameter is inserted into the text when the email is generated. The syntax is: ^<param name>^ where <param name> is the name of the substitution parameter.

Each message type includes a full list of available substitution parameters with type, description, and current value if known, at the bottom of the email customization page. For example, some strings used in emails for user management:

  • ^currentDateTime^ -- Current date and time in the format: 2017-02-15 12:30
  • ^emailAddress^ -- The email address of the person performing the operation -- see Look and Feel Settings.
  • ^errorMessage^ -- The error message associated with the failed audit processing -- see Compliance.
  • ^homePageURL^ -- The home page of this installation -- see Site Settings.
  • ^organizationName^ -- Organization name -- see Look and Feel Settings.
  • ^recipient^ -- The email address on the 'to:' line.
  • ^siteShortName^ -- Header short name -- see Look and Feel Settings.
  • ^supportLink^ -- Page where users can request support.
  • ^systemEmail^ -- The 'from:' address for system notification emails.
  • ^verificationURL^ -- The unique verification URL that a new user must visit in order to confirm and finalize registration. This is auto-generated during the registration process.
The list of parameters available varies based on which email type is selected from the dropdown. There are some specialized parameters providing more than simple substitution. For example, templates for report and dataset notifications include a ^reportAndDatasetList^ parameter which will include a formatted list of all the changes which triggered the notification.

Message Board Notifications

For Message board notification emails, there is a default message reading "Please do not reply to this email notification. Replies to this email are routed to an unmonitored mailbox." If that is not true for your message board you may change the template at the site or folder level. You may also choose whether to include the portion of the email footer that explains why the user received the given email and gives the option to unsubscribe. Include the parameter ^reasonFooter^ to include that portion; the text itself cannot be customized.

Format Strings

You may also supply an optional format string. If the value of the parameter is not blank, it will be used to format the value in the outgoing email. The syntax is: ^<param name>|<format string>^

For example:

^currentDateTime|The current date is: %1$tb %1$te, %1$tY^
^siteShortName|The site short name is not blank and its value is: %s^

Properties are passed to the email template as their actual type, rather than being pre-converted to strings. Each type has different formatting options. For example, a date field can be formatted in either month-first or day-first order, depending on local style.

For the full set of format options available, see the documentation for java.util.Formatter.

Folder-Level Email Customizations

A subset of email templates, like those for issue and message board notifications, can also be customized at the project or folder level.

  • Issue update
  • Message board daily digest
  • Message board notification
  • Specimen request notification
To access folder-level customizations for any of these templates, the easiest path is to use a Messages web part. You can add one to any folder if you don't already have one.

  • Viewing the Messages web part, open the (triangle) menu.
  • Click Email to open the submenu, then Folder Email Template.
  • The interface and options are the same as described above for site level templates. Only the subset of template types that can be customized at the folder level are listed. Select one.
    • Issue update
    • Message board daily digest
    • Message board notification
    • Specimen request notification
  • Customize the template as needed, then click Save.
  • If you added an empty Messages web part to make these changes, you can remove it from the page after customizing your templates.

Related Topics

Discussion

Was this content helpful?

Log in or register an account to provide feedback


previousnext
 
expand all collapse all