Admins: Feel free to move to the appropriate place but I struggled to find any documentation to get this integration working and thought I'd document it myself
MailChimp supports triggers of "When A Member Has Been Added To A List" & "When A New List Is Created"; for anything else you need to use a webhook.
While MailChimp has documentation here, it misses one important step to get it working with Power Automate; and that is that when you save your configuration in MailChimp it performs a GET request to check the validity of the URL you've provided. After this it only uses POST.
To set this up with Power Automate first create a trigger using "When a HTTP request is received" and under Show Advanced Options set the Method to GET.
Add an Action "Initialize Variable", set its Type to Object and Value to "Body" of the trigger "When an HTTP request is received"
At this point you can save the Flow and a URL is generated in the initial trigger...
Copy this URL and head on over to your MailChimp dashboard.
Select your Audience and in the dropdown on the right hand side go to Settings.
Down the bottom select Webhooks, and Create New Webhook.
Paste the copied URL from above into the "Callback URL" field, select what Updates you want, and hit Save.
At this point you can return to your flow and remove GET from the Method under Show Advanced Options and you should be able to test it out.
Just keep in mind that if you go to modify the MailChimp webhook at any time you'll have to set the method back to GET temporarily while MailChimp verifies the supplied URL again.
I then grab the email address from the provided $formdata using...
Hope this helps someone.
This is a helpful tutorial, and it all works for me up to a point. When I add another connection to the flow (such as SharePoint, though I've replicated the same behavior with several different connectors), it breaks the flow's trigger the next time I receive a call from the MailChimp webhook. The call itself doesn't even show up in the run history.
I've done a number of tests and it seems like this behavior is related to MailChimp sending the call with the 'x-www-form-urlencoded' content type. If I call the same flow from another service (such as Postman) using the 'application/json' content type, the flow still works fine.
The strange thing is that as long as the flow has no other connections, it seems to handle the form data just fine. I can select the variables that I want, parse the form data as JSON - anything at all, as long as it only uses built-in functions. As soon as I try to connect to a SharePoint list to save the data, the flow stops working.
I'd appreciate fixes if people have them, but even knowing if this is impacting other people would be helpful.
A workaround that I've heard but have not had time to test yet: Split it over 2 flows. The first flow simply catches the data and forwards the information you need on to a second flow (Either using a Child Flow or the HTTP connector). The second flow does all the work.
This allows you to keep any other connections out of your 1st flow, which is what seems to break the HTTP connector.
As I said, I haven't tested it because it's kind of annoying to have to create two flows to do one simple process. But it seems like it would probably work.
Check out how to claim yours today!
Check out new user group experience and if you are a leader please create your group
Test your skills now with the Cloud Skill Challenge.