Replacement Variables

For simple personalization of emails, you will often want to pass in dynamic content in replacement variables (often called vars for short).

Replacement variables are placed inside {curlybraces} and may not contain spaces or any characters besides letters, numbers, and underscores.

For example, you might open an email with a salutation:

Dear {name},

{name} will be replaced with the appropriate content for the user.

You can pass replacement variables in the following ways:

  • They can be set for a particular user using the email API call. All messages sent to that email address (both transactional and campaign emails) will be able to use the same replacement variable.
  • They can be passed for a particular transactional message using the send API call.
  • A campaign email can pull variables that will apply to the entire mailing using a Data Feed.

Replacement variables can be placed in the following parts of your email:

  • From Name
  • Subject
  • HTML Content
  • Text Content

Replacement variables are actually just the simplest form of a powerful and sophisticated template syntax that you can use for extreme personalization of emails, including functions, loops, and conditionals. For more on this topic, see: Syntax.

 
/var/www/docs.sailthru.com/htdocs/data/pages/replacement-variables.txt · Last modified: 2010/08/24 12:00 by Ian White
 
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki