In marketing, it helps to coordinate your marketing campaigns with other actions on your website and other channels such as text messages and direct mail. Webhooks are one way for you to sync Mailchimp activity with third-party apps.
In this article, we’ll look at ways you can create a webhook in the Mailchimp app.
Before you start
- In order to use webhooks, you must be on the Standard or Premium plan. If on the Essentials or Free plan, users can set up the webhook and see the feature, but will be prompted to upgrade before enabling the journey point. To change your plan type, visit the plans page in your account.
- We recommend webhooks for users who are familiar with custom coding. Contact your developer or hire a Mailchimp Expert if you need assistance.
- This article explains how to add webhooks in Mailchimp. To learn more about working with webhooks, check out our webhooks quick start guide.
How it works
When a contact performs a specific action in Mailchimp - such as reaching a certain point in a customer journey or updating a profile - a webhook triggers an event in a third-party app. The webhook sends an HTTP request to a URL with instructions and details about the event. The app or integration monitoring that URL then sends a text message to the contact or performs some other action in a third-party app.
Here are some terms you’ll come across as you work with webhooks in Mailchimp.
A webhook is an HTTP request that allows one app to send information to another.
Headers describe something about the request. Headers can include any information that the receiving app needs to have in order to process the request. Many apps ask for headers to contain a key type ("Key") and a key value ("Value").
The content type option lets you choose the programming language for the body of the request. Currently, the editor only accepts JSON and FormData.
The payload is the body of the request. The correct format of the body is determined by the app connected to the webhook.
Webhooks as a Customer Journey point
A Customer Journey is composed of specific starting points, actions, and rules that you set based on your marketing goals. To build your journey, you’ll choose and arrange these elements on a journey map.
Here’s how to add a webhook as a Customer Journey point.
- Click Automations, then click All journeys.
- Click the Create Journey button or click Finish Setup next to an existing journey.
- To add a journey point, hover your cursor over the plus icon (+) on the step where you want the webhook to occur.
- Click Add a journey point.
In the webhook builder module, complete the fields to configure your webhook. The Webhook name, URL destination, Username, and Password fields are required.
Once you’ve configured your webhook, click Save to add it as a journey point.
Nice job! When you start or resume your journey, the webhook will trigger once the user gets to that journey point. The number of requests sent will appear on the journey point itself.
Webhooks as a Campaign Manager touchpoint
Mailchimp’s Campaign Manager is an end-to-end campaign planner. Set an objective, then organize tasks, events, emails, and webhooks from a centralized planner.
To add a webhook as a Campaign Manager touchpoint, follow these steps.
Click Campaigns, then click Campaign Manager.
Click the Create campaign button or click on the active campaign you want to add a webhook touchpoint to.
Click the Add touchpoint drop-down, then click Webhook.
In the webhook builder module, complete the fields to configure and schedule your webhook.
The audience you selected during campaign setup is used by default. If you don’t want to trigger a webhook action for your entire audience, select an existing segment or tag from your audience in the Segment or Tag section of the module.
Once you’ve configured your webhook and set a date and time, click Schedule webhook to add it as a campaign touchpoint.
Excellent! You can view your webhook touchpoint on your calendar, and after its scheduled date and time, it will show as completed.
Audience webhook configuration
To send updates about your audience to another app, you can configure an audience webhook. Webhooks can send a request to the URL of your choice when specific updates happen in the audience, such as when someone subscribes or when a profile is updated.
Here’s how to add a webhook to your audience.
- Click Audience, then click Audience dashboard.
- If you have more than one audience, click the Current audience drop-down and choose the one you want to work with.
- Click the Manage Audience drop-down and choose Settings.
Click Create New Webhook.
Enter a Callback URL. This is the URL the webhook sends requests to.
Check all the actions that you want to trigger a webhook. Here are the available options:
- Profile updates
- Cleaned address
- Email changed
- Campaign sending
You can also choose to send updates only when a change is made by a subscriber, by an account admin, or via the API.
That’s it! When one of the selected actions occurs, the webhook will send a request to the URL that you entered.