Let’s Send an Email Automatically in the Middle of a Workflow (HTML Email: Markdown chapter)

In this section, over two parts we will describe how to enhance the visual appeal of your emails using two different functions. This time, we will explain how to use Markdown to decorate email text with basic features such as headings and bullet points. Next time, we will cover how to embed images into the body of emails. Both of these functions help make email content easier to understand.

 Previous Post: HTML Email chapter

Converting Markdown to HTML and Embedding in Email Body

Introduced in Questetra in Version 16.2, Markdown notation is a simple way to provide decoration and formatting to text used in the workflow platform.

Here, we will demonstrate some of the new features of the [Throwing Message Intermediate Event (email)] step, which will enable you to retain Markdown formatting even when sending emails externally using Questetra. It is now possible to reference String-type (Markdown) Data Items in the Body (HTML) section of a [Throwing Message Intermediate Event (email)], which enables text decoration used in a process input form to be copied to the body of an email.

We will use a simple app to demonstrate how this is done, and it must contain just two elements, all of which are available in the Basic edition of Questetra: A String-type  (Markdown) Data Item, and a [Throwing Message Intermediate Event (email)] step. This app can perform the function of distributing a meeting agenda or minutes to attendees in an easy-to-read format.

String-type (Markdown) Data Item

The String-type (Markdown) Data Item should be set to [Editable] in the Editing permission tab of the Human Task configs.

Editing permissions for the “Agenda/Minutes Entry” Human Task
Editing permissions for the “Agenda/Minutes Entry” Human Task

In this way, you can enter your desired markdown in the Input Form of the task when executing a process. The image below shows a basic example of the types of markdown that can be used when inputting to a String-type (Markdown) Data Item.

Input Form for the “Agenda/Minutes Entry” Task
Input Form for the “Agenda/Minutes Entry” Task

Please refer to the following pages for more examples of markdown that can be used in Questetra.

Related Articles
・Reference: R1020: Markdown Samples (for beginners)
・Reference: R1021: Markdown Samples (for experts)

Throwing Message Intermediate Event (email)

In the [Throwing Message Intermediate Event (email)] settings screen, use [Insert reference…] to select the data item Meeting Agenda / Minutes in the Body (HTML) section. We will also label the data item with some conventional HTML, applying a heading “Meeting Notes” within <h2></h2> heading tags.

In order to convert the Markdown into HTML, we must add the following additional code around the Meeting Agenda / Minutes reference

#{#markdown.toHtml(#q_meeting_agenda_minutes)}

where the section “#q_meeting_agenda_minutes” is the field name of the Meeting Agenda / Minutes data item. By using this expression to convert the markdown text into HTML, the formatting of the text can be retained when it is sent in an email.

With these settings, when the process is run, an email will be automatically sent to the recipient which displays the markdown text in the format it is intended.

Email displaying converted HTML text in markdown format
Email displaying converted HTML text in markdown format

Related Articles
・Modeling Elements: Throwing Message Intermediate Event (Email)

Summary

In this article, we introduced the first of two key features to improve the appearance of your emails. We explained how to use Markdown to add formatting such as headings and bullet points to the email body. This makes the content more visually organized and easier for recipients to understand.

Next time, we will explain the second feature: how to embed images within the email body. Properly inserting images can make emails more engaging and clearer.

Next is HTML Email: Inline Images chapter

Scroll to Top

Discover more from Questetra Support

Subscribe now to keep reading and get access to the full archive.

Continue reading