Lob's website experience is not optimized for Internet Explorer.
Please choose another browser.

Arrow Up to go to top of page
Automate Direct Mail With Iterable
Tutorials
February 22, 2023

Automate Direct Mail With Iterable

Author Avatar
by 
Eamon Barisone

Overview

Iterable is a cross-channel marketing platform that powers unified customer experiences and empowers you to create, optimize and measure every interaction across the entire customer journey. Automated connections in Iterable, called Journey Webhooks, can be set up in minutes with no coding. Webhooks can automate your day-to-day tasks and enable mail sends with Lob.

There are 3 common scenarios in which Iterable Journeys can trigger Lob mail sends:

  1. Single triggered mailpieces from individual user actions
  2. A regular job is run, resulting in mail being sent to all users who meet specific criteria
  3. An audience list is exported from Iterable and uploaded to Lob, and mail is generated for each user in the list

Each Journey Webhook you create will connect to an HTML template that you have stored in your Lob account. You will map your Iterable data fields to the dynamic Lob merge variables in the HTML template, and trigger mail sends via either an individual user action or to a group of users.

Getting started with Lob

This tutorial assumes you have signed up for a free Lob account. You can then begin sending API requests right away using your secret Test API key, at no cost and without entering any payment info. (Instantly begin sending real mail by simply adding a payment method to your account and switching to your live API key.)

We also assume you have an HTML template(s) for your mailpiece. (Don't have one? Check out our direct mail template gallery.) To leverage HTML creatives in Lob, you will want to save your HTML as a template within Lob (in your dashboard under HTML Templates), or host your HTML and generate a corresponding hosting URL. These can be passed to Lob from Iterable, but you are not able to pass a full HTML string directly to Lob from Iterable.

Getting started with Iterable

To get started with Iterable, you will need to sign up directly with Iterable (see Request Demo on Iterable website), or have your Iterable account enabled by your company.

How do I connect Iterable to Lob?

1. Login to your Iterable Account.

2. Navigate to "Integrations" -> “Journey Webhooks”

Automate Direct Mail With Iterable image 2



3. Then click on ‘New webhook’ at the top of the page

Automate Direct Mail With Iterable image 3





4. Configure as follows:

Automate Direct Mail With Iterable image 4

  • Endpoint: Make sure the URL matches the resource you want to create (i.e., that you are sending postcard requests to the postcard endpoint). See URLs here.
  • Authentication: None
  • Custom headers: Use the Authorization Header and your Base64 Encoded API key to connect your Lob account. You can use a Base64 Encoder tool to encode your (Test) API Key. Use the encoded key as the value for the Authorization header and encode your secret API key with a colon after the key like this Basic {{ 'YOUR_LOB_API_KEY:' | base64_encode
  • Body: Select ‘URL-encoded Form’, then add form fields below to map the required Lob parameters to the associated attributes within Iterable. See the image below for an example.
Automate Direct Mail With Iterable image 5

5. Map your variables. The fields on the left are the required Lob request parameters, and your corresponding data fields are on the right.

  • The right column is where you can dynamically map to Iterable attributes, by using the corresponding Iterable variable for a given attribute.
  • Iterable variables will need to be enclosed like so: {{your_variable}}. For example, if you have a field that maps to “to{name}” in your data and you want the variable first_name to be used as that mapping, you would put {{first_name}} next to the “to{name}” field on this page.
  • Be sure to map to all of the necessary merge variables. For example, if you have a merge variable “name” in your template you need to add a form field of “merge_variables[name]” and set the desired value on the right.

6. Click ‘Create Webhook.’

7. Ensure that you are mapping all of the required HTML templates. For example, Postcards and Self Mailers will utilize two templates, one each for the front and back. Letters have just one template, mapped to the parameter ‘file’ on the left side

8. Click ‘Save’ on the right when you are finished.

9. Navigate to “Messaging”> “Journeys”

Automate Direct Mail With Iterable image 6

10. Click on the Journey you want to incorporate this webhook into, or create a new Journey.

11. Find the event that will trigger your Lob webhook (for example, a customer is Added to a List, or opened an email), then drag in the “Call webhook” tile and place it after that event in the Journey.

Automate Direct Mail With Iterable image 7

12. Open up that Webhook, and toggle on ‘Use Preset Journey Webhook’, then select the webhook you have created.

Automate Direct Mail With Iterable image 8



13. After you have successfully set up your Journey, send a test trigger by clicking on ‘Test Journey’. Check to see whether Iterable notes any errors.

14. Assuming no errors are caught in Iterable, head over to your Lob dashboard and verify the results of the test; you can see the new mailpieces that were generated from your Iterable journey.

Send Mail!

Again, we recommend testing any triggered by first using your Test Lob API Keys, and ensuring that the resulting records created in Lob match your expectations. When you are ready to send actual mail, you’ll need to input a payment method for live sends and use your Live Lob API Key—then you are off to the races!

Continue Reading