Skip to content

Lob is an online service that allows you to send direct mail to your users.

The Braze and Lob integration leverages Braze webhooks and the Lob API to send mail like letters, postcards, and checks through the mail.


Requirement Description
Lob account A Lob account is required to take advantage of this partnership.
Lob API key You Lob API key can be found under the settings section under your name in the Lob dashboard.


Step 1: Select Lob endpoint

The HTTP URL to request in the webhook is different for each action you can make to Lob. In the following example, we use the postcards API endpoint Visit the complete endpoint list to select the endpoint appropriate for your use case.

API endpoint Available endpoints /v1/addresses

Step 2: Create your Braze webhook template

To create a Lob webhook template to use in future campaigns or Canvases, navigate to Templates > Webhook Templates in the Braze platform.

If you would like to make a one-off Lob webhook campaign or use an existing template, select Webhook in Braze when creating a new campaign.

In your new Webhook template, fill out the following fields:

  • Request Body: Raw Text

Request headers and method

Lob requires an HTTP Header for authorization and an HTTP method. The following will already be included within the template as a key-value pair, but in the Settings tab, you must replace the <LOB_API_KEY> with your Lob API key. This key must include a “:” directly after the key and be encoded in base 64.

  • HTTP Method: POST
  • Request Headers:
    • Authorization: Basic <LOB_API_KEY>:
    • Content-Type: application/json

Request body code and webhook URL shown in the Braze webhook builder compose tab.

Request body

The following is an example request body for the Lob postcards endpoint. While this request body is provided in the base Lob template in Braze, if you wish to use other endpoints, you must adjust your Liquid fields accordingly.

"description": "Demo Postcard",
"to": {
    "name": "{{${first_name}}} {{${last_name}}}",
    "address_line1": "{{custom_attribute.${address_line1}}}",
    "address_city": "{{custom_attribute.${address_city}}}",
    "address_zip": "{{custom_attribute.${address_zip}}}",
    "address_country": "{{custom_attribute.${address_country}}}"
"front": "",
"back": ""

Step 3: Preview your request

At this point, your campaign should be ready to test and send. Check the Lob dashboard and the Braze developer console error message logs if you run into errors. For example, the following error was caused by an incorrectly formatted authentication header.

A message error log showing the time, app name, channel, and error message. The error message includes the message alert and the status code.

New Stuff!