EmailTemplate v1.2

Create, edit or retrieve your email templates.

What can I do with emailTemplate?

EmailTemplate provides access to all the custom templates in an account. Users can then log into the interface and use these templates to create email campaigns and send them to subscribers.

  • Create new templates.
  • Modify existing templates by issuing PUT.
  • Retrieve the HTML of any existing custom template.

GET /emailTemplate or /emailTemplate/:id

AttributeTypeFilterSortDescription
id
intYesYesUnique ID of the email template.
name
stringNoYesTemplate name. Maximum length is 128 octets.
description
stringNoNoDescription of the template. Maximum length is 255 octets.
content
stringNoNoTemplate HTML content.
thumbnailurl
string/nullNoNoThe URL at which a thumbnail preview of the rendered template content can be found. NULL if the thumbnail image has not yet been generated.
cdate
decimalNoYesTemplate creation timestamp.
mdate
decimalNoYesLast modification timestamp.

HEAD /emailTemplate or /emailTemplate/:id

AttributeTypePresenceDescription
id
intOptionalUnique ID of the email template.

POST /emailTemplate

AttributeTypePresenceDescription
name
stringRequiredTemplate name. Maximum length is 128 octets.
description
stringOptionalDescription of the template. Maximum length is 255 octets.
content
stringRequiredTemplate HTML content.

PUT /emailTemplate or /emailTemplate/:id

AttributeTypePresenceDescription
id
intRequiredUnique ID of the email template.
name
stringOptionalTemplate name. Maximum length is 128 octets.
description
stringOptionalDescription of the template. Maximum length is 255 octets.
content
stringOptionalTemplate HTML content.

DELETE /emailTemplate or /emailTemplate/:id

AttributeTypePresenceDescription
id
intOptionalUnique ID of the email template.

Examples

JSON response

{
    "id"           : 123456,
    "name"         : "Three-column newsletter",
    "description"  : "Responsive template with three columns; article layout suitable for a newsletter",
    "content"      : "<html> [...] </html>",
    "thumbnailurl" : "http://someserver.com/123/456/789/thumbnail.png",
    "cdate"        : 123456789,
    "mdate"        : 123456789
}