MVT message templates
Every MVT rule points to a template that defines the email it sends. Templates are managed in Settings > Email Templates > MVT Messages, in the same place where the rules themselves are configured.
A template consists of two parts:
-
Subject – the email subject line,
-
Body – the message content.
Both parts support the same set of dynamic fields, so you can put e.g. the registration and the route straight into the subject.
Leon ships a set of default templates (one per scenario). You can edit them, or add your own custom templates and assign them to selected rules. Each rule (a scenario for a given aircraft) uses exactly one template, but the same template can be reused by many rules.
Note: default templates and custom templates are independent copies. Changing a default template does not update custom templates that were created from it, and vice versa.
How to insert dynamic data
Dynamic data is inserted using field tags written in double curly brackets:
{{REG}} {{ADEP_ICAO}}/{{ADES_ICAO}} airborne {{TO}}Z
renders as:
D-ABCD EDDM/LFPG airborne 1205Z
Rules to remember:
-
Tag names are case-sensitive and always written in capital letters.
-
A tag whose data is not available renders as an empty string – it never breaks the message and never shows an error. For example,
{{LDG}}used in a Take off template will simply come out empty, because the aircraft has not landed yet. -
All times render in HHMM format without a colon (
1205, not12:05) – the standard movement-message convention.
Showing a part of the message only when data exists
You can wrap a fragment of the message in a conditional section, so it appears only when the given field has a value:
{{#DELAY}}Delay: {{DELAY_REASON}} ({{DELAY_TIME}}){{/DELAY}}
The opposite (show only when the field is empty) uses ^ instead of #:
{{^ATA}}Still airborne{{/ATA}}
Important: an opening section must always have a matching closing tag (
{{#DELAY}}…{{/DELAY}}). An unmatched section makes the whole message fail to render, and the email is silently not sent.
There are no loops – a template always describes one single flight. Lists that could contain many entries (for example passenger names) are delivered as ready-made, comma-separated text in a single field, such as SHOW_PAX_LIST.
Available fields
Times
Thirteen time bases are available. Each of them can be used in ten variants, so you can print a full timestamp or just a part of it, in UTC or in local time:
|
Variant |
Example tag |
Renders |
|---|---|---|
|
Time (UTC) |
|
|
|
Time (local) |
|
|
|
Date (UTC) |
|
full date |
|
Date (local) |
|
full date |
|
Day (UTC / local) |
|
day of month |
|
Month (UTC / local) |
|
month |
|
Year (UTC / local) |
|
year |
Available time bases:
|
Base tag |
Meaning |
Local time based on |
|---|---|---|
|
|
Calculated Take-Off Time (slot) |
ADEP |
|
|
Slot status (e.g. slot cancelled) |
– |
|
|
Estimated Time of Departure |
ADEP |
|
|
Scheduled Time of Departure |
ADEP |
|
|
Target Off-Block Time |
ADEP |
|
|
Target Start-up Approval Time |
ADEP |
|
|
Target Time Over |
not available – |
|
|
Actual off-block time |
ADEP |
|
|
Actual take-off time |
ADEP |
|
|
Estimated Time of Arrival |
ADES |
|
|
ETA calculated as ATD + estimated flight time |
ADES |
|
|
Scheduled Time of Arrival |
ADES |
|
|
Actual landing time |
ADES |
|
|
Actual on-block time |
ADES |
The flight date itself (not a clock time) is available as DATE, DATE_LT, DAY, DAY_LT, MONTH, MONTH_LT, YEAR, YEAR_LT. It is taken from CTOT, or from STD when there is no CTOT, and is replaced by the actual departure time once ATD is entered.
Flight and aircraft
|
Tag |
Description |
|---|---|
|
|
Flight number |
|
|
Flight number in ICAO format |
|
|
Flight number in IATA format |
|
|
Aircraft registration |
|
|
Aircraft type |
|
|
Trip number |
|
|
Operator name |
Airports
|
Tag |
Description |
|---|---|
|
|
Departure airport |
|
|
Destination airport |
|
|
Diversion airport |
Crew
|
Tag |
Description |
|---|---|
|
|
Number of crew members |
|
|
Captain |
|
|
First officer |
|
|
Flight attendant |
Additional crew members of the same position are available by adding a number: CPT2, CPT3, CPT4, FO2–FO4, FA2–FA4, each with _NAME and _SURNAME.
Passengers
|
Tag |
Description |
|---|---|
|
|
Number of passengers |
|
|
Number of passengers padded to three digits (movement-message format, e.g. |
|
|
Announced number of passengers |
|
|
Passenger breakdown |
|
|
Passengers marked as on board, as a comma-separated list |
|
|
Passengers not marked as on board, as a comma-separated list |
Load
|
Tag |
Description |
|---|---|
|
|
Load figures including the unit (kg / lb) |
|
|
The same figures as a plain number, without the unit |
Fuel
|
Tag |
Description |
|---|---|
|
|
Fuel on off-block |
|
|
Fuel on take-off |
|
|
Fuel on landing |
|
|
Fuel on on-block |
Fuel values are printed together with the unit.
Delays and ATFM
|
Tag |
Description |
|---|---|
|
|
Delay code and duration combined |
|
|
Delay code |
|
|
Delay reason |
|
|
Delay duration |
|
|
ATFM regulation |
|
|
Regulation cause code |
|
|
Regulation cause description |
Durations
|
Tag |
Description |
|---|---|
|
|
Estimated elapsed time |
|
|
Taxi time |
|
|
Flight time |
Notes and other
|
Tag |
Description |
|---|---|
|
|
Flight notes |
|
|
Notes from the related quote |
|
|
Client |
|
|
User who triggered the message (empty for automatic, system-triggered messages) |
|
|
Hotel |
|
|
Next information |
Good to know
-
All fields are available in every scenario. There is no separate field set per scenario – a Take off template and a Landing template can use exactly the same tags. Fields that do not apply yet simply render empty.
-
"Aircraft ready for next client" describes the flight that has just landed. It does not expose separate fields for the next leg – the next leg is only used to decide whether the message should be sent at all.
-
"CTOT change" provides the current
CTOTandCTOT_STATUSonly. The previous value is not available in the template. -
"Missing take-off" is sent precisely because the actual times are missing, so
TO,BLOFFand related tags will be empty.STD,ETD,CTOT, airports, crew and passenger fields work as usual. -
Messages are sent as HTML, so basic formatting such as
<b>or<br>can be used in the body. Special characters coming from data fields (for example&in notes) are escaped automatically. -
A typo in a tag name is not reported as an error – it simply renders as nothing. If a value is unexpectedly missing from a delivered email, the tag spelling is the first thing to check.