Each mail sent with Mailster is technically a multi-part message in MIME format. It contains three sections:

  1. Header
  2. Plain Text Part
  3. HTML Part

Next to some default header values, Mailster adds these header properties to each outgoing mail

X-Mailer: Mailster 2.3.1 (5.2.22)
X-Mailster: 3b4160f015ca9e739b8ca942dfe9e8b1
X-Mailster-Campaign: 28
X-Mailster-ID: be07c931957062f38291a039d49ccf2f

X-Mailer: Mailster X.X.X (Y.Y.Y)

This identifies that Mailster is the sender of this message. It contains the version number of Mailster (X.X.X) as well the version number of the used PHPMailer (Y.Y.Y)

X-Mailster : [md5hash]

This contains the hash of the subscriber stored in your database. It’s unique to each Mailster installation.

X-Mailster-Campaign: [ID]

This contains the ID of the campaign. It’s the same as the post ID from any of your posts.

X-Mailster-ID: [md5hash]

A unique hash is generated on plugin activation. This is used for bounce handling to identify the correct installation. It’s unique to each Mailster installation.

Some headers are required by email services like Gmail or Yahoo.

List-Unsubscribe: <https://example.com/mailster/unsubscribe/28/>
Precedence: bulk

List-Unsubscribe

Contains a link to your unsubscribe age and makes it easy for users to opt-out. If you have automatic bounce handling enabled a mailto: address will also be included.

Precedence: bulk

A required header if you send bulk emails. Major email providers will notice if you remove that and more likely to mark your message as spam.

Adding custom headers

You can add a custom header to every outgoing mail with some coding:

add_action( 'mailster_initsend', function($mailobject){ 
    $mailobject->add_header( 'X-Custom-Header', 'Custom Value' );
} );

This will add a X-Custom-Header header with the value of Custom Value

Tagged: