Custom Headers

You may add as many as 5 custom header to your email messages. All headers must begin with “X-” or your API request will be rejected. Customer headers can be useful for inserting data into your messages that may help you with customer support, seedlist testing, etc. Supplying custom headers in your API calls is easy, and works in a very similar manner as the attachment parameters. The example below shows you how you would add 2 headers in a Transactional job.

Pass in the following 4 parameters in the API call:

  • HeaderName.1=X-CampaignId
  • HeaderValue.1=12345
  • HeaderName.2=X-RecipientId
  • HeaderValue.2=2897423894

In the resulting email you would see the following headers in your message source:

X-CampaignId: 12345
X-RecipientId: 2897423894