Thursday, August 19, 2010

New method to specify Transactional Group using the SMTP service

We've introduced a new method to assign a transactional email to a Transactional Group. Along with specifying the Transactional Group in the Subject line, you can now also specify it in a custom X-Header.

If you're using the JangoMail SMTP server to send transactional email, you're likely familiar with the concept of Transactional Groups -- categories to which you can assign various types of transactional emails. For example you may have the following Transactional Groups set up in your account:

1. Order Confirmations
2. Renewal Reminders
3. Thank Yous

Previously you could assign an email to a particular Transactional Group by specifying the Transactional Group's name in the Subject Line surrounded by curly brackets. For example, if I sent an email with the Subject:

Subject: Thanks for your purchase {Thank Yous}

...then this email would get assigned to the Transactional Group called "Thank Yous", and the email would be sent with the curly brackets and the part in between stripped out.

Now, there's an alternate way to assign an email to a particular Transactional can specify an X-header with the Transactional Group's ID. If you're sending emails through programatically, such as through .Net or PHP code, and if you have the ability to add an X-header to the email message, you can use this method. The format is as follows:

X-TransGroupID: TransactionalGroupID

For example, if the Transactional Group "Thank Yous" had an ID number of 78929, then you would add the header:

X-TransGroupID: 78929

Specifying an X-TransGroupID header overrides any Transactional Group designation in the Subject Line.

You can retrieve the ID number of a Transactional Group by going to the Transactional Reporting section of your account, where the various Transactional Groups are listed, along with their delivery statistics and their ID numbers.