Add priority headers I realize priority headers are something of the past for the most part, but I was wondering if it's possible to add additional headers (eg. Priority Flag) to an email sent from Webform (Drupal 8 version)? 

Similar to this question - https://www.drupal.org/forum/support/post-installation/2013-08-29/adding-priority-flag-to-email-sent-by-webform-module

I understand this is possible with a remote post, but this is strictly for sending an email.

Any help is apprciated.

Just for context, here is how it can be set strictly in a PHP email.

$headers = "MIME-Version: 1.0\n" ;
$headers .= "Content-Type: text/html; charset=\"iso-8859-1\"\n";
$headers .= "X-Priority: 1 (Highest)\n";
$headers .= "X-MSMail-Priority: High\n";
$headers .= "Importance: High\n";

$to = 'bob@email.com';
$subject = 'High Importance Email Testing';
$message = 'Testing email importance, please ignore';
$status   = mail($to, $subject, $message,$headers);


I managed to get the module working as I'd like, thanks to @jrockowitz

Here is the final module

&lt;?php
/**
* implements hook_mail_alter()
*/
function priority_headers_mail_alter(&amp;$message) 
{
    // only alter webforms
   if (strpos($message['id'], 'webform_email_web_requests') === 0) 
   {    
       //Get webform submission
       $webform_submission = $message['params']['webform_submission'];

       //Get the value from the priority field
       $priority = $webform_submission-&gt;getElementData('priority');

       if($priority == 'Critical')
       {
           /*setting priority headers*/
           $message['headers']['X-Priority'] = '1 (Highest)';
           $message['headers']['X-MSMail-Priority'] = 'High';
           $message['headers']['Importance'] = 'High';          
       }
   }
}
There is a hook for that... 

hook_mail_alter()  

For an example see webform_mail_alter()