Using the Transactional API Trigger
Transactional messages result from a significant or unusual event in a customer’s life; for example, a purchase, a larger than normal bank deposit, birthday, graduation, marriage, website visit, or direct email conversation with a company.
Typically, you would send a transactional (or event-based) message immediately after an event occurs, but you can also sequence them at strategically-timed intervals.
Purchase notifications, payment and shipping status, renewal reminders, and special offers are all examples of transactional messaging.
The EmailLabs Transactional API trigger is designed for users who know of a transaction on their website.
It allows them to specify a recipient of the message, the envelope information, and the message itself and route that information through the EmailLabs transactional processors.
By doing this, they are taking advantage of EmailLabs’ advanced reporting and deliverability.
- Create the trigger stub in EML to hold reporting data.
- Follow the normal trigger creation process.
- When you come to Select Action, select API fire-trigger method is invoked
- Create the default message by using the create message option. The default message is used if you pass data that does not contain a message to deploy. This is useful when you have a standard thank you or welcome message to deploy.
- Save the trigger, make note of the trigger ID.
- Generate a script to utilize the API call. API call data below:
- Activity: FIRE-TRIGGER: Transfers data to EmailLabs to enable a transactional message to be sent from the system. Must be paired with a trigger stub in the EmailLabs application. See help manual for full implementation.
- Functional Description
Trigger_id[required]
: Informs the system which trigger stub to use for reporting and default message (if using).Recipients[requiredl]
: Comma delimited list of email address to receive email. Can be one address or many.Recipients_data[optional]
: Location of CSV or TXT file with large list of recipients. Must be in URLUniform Resource Locator. An Internet address, as well as a standard method of naming files on the Web. A URL begins with a protocol name (such as http), followed by a colon and two forward slashes(//). Next comes the name of the internet server that the file is stored on, followed by directories that hold the file, separated by forward slashes(/). The filename comes last, as shown in the following example: http://www.mycompany.com/whatsnew.htm format (http://example.com/data.csv).Subject[optional]
: Subject of the message, if not using the default specified in the user interface.From_email[optional]
: From email address to be used in the message envelope, if not using the default specified in the user interface.From_name[optional]
: YYYY-MM-DD - Limits the results to this end dateTracking[optional]
: Enables open and click tracking for the message, if not using the default message specified in the user interface.Message[optional]
: URL of location to fetch HTMLHypertext Markup Language. A set of tags used to mark the structural elements of text files. HTML files include tags that create hyperlinks to other documents on the Internet. content or actual raw HTML (URL encoded).
Parameter | Req? | Type | ID | Value |
---|---|---|---|---|
Site_ID
|
Yes | N/A | N/A | (Site ID of account) |
MLID
|
Yes | N/A | N/A | (Mailing list ID of trigger) |
trigger_ID
|
Yes | Extra | trigger_ID | (id of trigger) |
recipients
|
No | Extra | recipients | (single or comma delimited list of recipients) |
recipient_data
|
No | Extra | recipient_data | (URL location of CSV file with recipients) |
subject
|
No | Extra | subject | (Subject Line) |
from_email
|
No | Extra | from_email | (From Email Address) |
from_name
|
No | Extra | from_name | (From Name) |
tracking
|
No | Extra | tracking | on |
message content
|
Yes | Extra | message | URL of location to fetch HTML or full HTML. |
EXAMPLE:
Type=triggersfdd
Activity = fire-trigger
Input=
<DATASET>
<SITE_ID>123</SITE_ID>
<MLID>345</MLID>
<DATA type="extra" id="trigger_id">123</DATA>
<DATA type="extra" id="recipients">alice@example.com,bob@example.com</DATA>
<DATA type="extra" id="recipients_data">http://example.com/data.csv</DATA>
<DATA type="extra" id="subject">Subject</DATA>
<DATA type="extra" id="from_email">reply@lyris.com</DATA>
<DATA type="extra" id="from_name">Lyris</DATA>
<DATA type="extra" id="tracking">on</DATA>
<DATA type="extra" id="message">http://example.com/message.html</DATA>
</DATASET>
- You can utilize the default message in the trigger if you choose. Simply send only the trigger ID and the recipient information.
- You can send a single recipient or a comma delimited list of recipients. You can also send a CSV file of recipients via a web location.
- You can use personalization inside the message being sent along, simply use the existing mail merge tags or dynamic content.