Connecting Klaviyo to Poplar

Before integrating and sending tests with Klaviyo, make sure you've completed the following:

  • Create a campaign in Poplar

  • Upload creative (can be a placeholder creative for testing purposes)

  • Locate both your Production Access Token and Test Access Token on the API page of your Poplar Account

For the webhook request to hit our API and be accepted, there must be an active campaign with creative uploaded - otherwise an 400 error will be sent back.

Step 1: Flows

From your Dashboard, navigate to your Flows page and use the Create Flow button, or select an existing one by clicking Edit Flow.

Step 2: Actions

If you're creating a flow from scratch, select your Trigger event, set any necessary filters, and click Save the Done to access the Actions step.

Drag and drop the Webhook action into your flow:

Step 3: Webhook Configuration

Under the configuration settings on the left, you'll want to enter the following values to trigger a mailing by sending data to our Mailing API:

We strongly recommend using the Test Access Token provided in the API section of your Poplar account, to ensure your trigger is set up successfully. After confirming the requests are successfully coming through to the History tab of your campaign for a period of time, swap in the Production token to go live.

Your JSON payload should contain all the data you'd like to share with the platform. This includes recipient info such as name, address, customer ID, and/or email, along with any custom merge tags that may be present if you're using dynamic creative.

campaign_id and optionally creative_id will also have to be included in the payload, to tell the trigger which Poplar campaign and creative to point to. If creative_id is not specified, the platform will automatically randomize between all active creative under the campaign (ideal setup for A/B testing). If a creative is set to Default, the trigger will only fire the defaulted creative.

Emails for Address Enrichment

If you have customer email addresses and want to use them to mail with Poplar's Address Enrichment feature, use the code below as a template for your JSON Body:

  "recipient": {
    "email" : "{{ person.email|default:'' }}"
  "campaign_id": "***Insert Campaign ID***",
  "creative_id": "***Insert Creative ID***"

Address Data

If you have customer Shipping or Billing addresses stored in Klaviyo and want to use them for mailing, use the code below as a template for your JSON Body:

  "recipient": {
      "email" : "{{ person.email|default:'' }}",
      "first_name": "{{ person.first_name|default:'' }}",
      "last_name": "{{ person.last_name|default:'' }}",
      "company": "{{ person|lookup:'$organization'|default:'Company' }}",
      "address_1": "{{ person|lookup:'$address1'|default:'' }}",
      "address_2": "{{ person|lookup:'$address2'|default:'' }}",
      "city": "{{ person|lookup:'$city'|default:'' }}",
      "state": "{{ person|lookup:'$region'|default:'' }}",
      "postal_code": "{{ person|lookup:'$zip'|default:'' }}"
  "campaign_id": "***Insert Campaign ID***",
  "creative_id": "***Insert Creative ID***"

Conditional Splits

If some of your customers in the flow have properties filled out for only email or an email & address you'll want to use a conditional split block to filter on a customer address field. Then you can set up two webhooks one specific for email append and one with address fields.

Without the conditional split we'll respond with a 400 error on any customers triggered in the flow that have blank address data.

Step 4: Preview Webhook & Test Trigger

After entering your JSON Body code, click Preview Webhook to view a sample customer profile and ensure all the desired data is being pulled into each field.

The Profile Properties will show all the data for the sample customer, and the Payload Preview will show what data is being pulled into the webhook to be passed to the platform.

Data that appears under Profile Properties isn't guaranteed to be passed to the platform, always make sure the desired data is present in the Payload Preview as well.

Send Test Request to push the webhook preview to Poplar to confirm the connection is successful. If the trigger goes through successfully, you'll see a 201 "Error" in Klaviyo:

If you receive anything but 201 or if you receive a 400 error, consult our Common Questions section below or reach out to support@heypoplar.com for assistance.

History Tab

Head to the History tab of your campaign within your Poplar account to see successful tests come through:

Click into one of the mailers to see a PDF proof with the user data applied. Scroll down to the Request Details to confirm the data coming through the platform matches your Klaviyo JSON payload.

Step 5: Go Live!

Once you've confirmed the connection is successful and customer data is coming through to Poplar as desired, swap your Production Access Token in place of your Test token under HEADERS. Make sure to Save your updates, the set your Webhook action to Live!


The manual setting will accumulate customers when they reach this step in the flow, and will only pass to Poplar if triggered manually.

Common Questions

Why am I receiving a 403 Error after cloning an existing webhook?

For security purposes, if you clone a webhook the access token entered under HEADERS will be hashed at the end:

We recommend copy and pasting your access token again, then re-trying the test to see if it is successful.

Last updated