When contact added to Mautic from n8n emails sent twice or more

Hello, I hope everyone is feeling great.

When I update a contact, update contact campaign or segment with the Mautic node the emails are sent several times as if the contact is added repeatedly to the campaign.

I have tried adding the contact through segments and directly into the campaign and the behavior is the same. And when I check the profile of the contact in Mautic the logs shows that the campaign ran only once.

This only happens when I use Mautic with n8n as I have other campaigns running and this issue is not happening.

This is my workflow:

1 Like

How are you triggering the workflow? Is it possible that the workflow executes multiple times hence the various emails?

It’s triggered when I move a card to a specific Trello list. But before sending the info to Mautic the workflow has an if node.

Is it possible that the if node it’s not filtering the data correctly? You can check the executions tab and see what each run did. That way, you can discard that posiblity.

I checked the executions and the workflow ran 5 times.

Any reasons why this could be happening?

I found the problem. I have some automations on my board with Buttler whenever a card is move to the list I’m trying to use and this updates the card on some fields. I deactivated the automations and the workflow runs as expected.

Now I need to figure out how to run these rules after the card is move and not at the same time.

Thanks.

3 Likes

Hey @zerog,

I did something very similar with Trello. I don’t have the workflow with me, but I used the Trello Trigger node to start the workflow. I added an IF node to check if the card moved from board A to board B, and continued the workflow only if this condition was met.

I have not used Buttler, but can it make API calls? If so, you can create a workflow with the Webhook node. Buttler can send a request to that webhook URL to trigger the workflow in n8n.

Hope this helps :slight_smile:

Thank you @harshil1712 I did as you stated and it worked great

1 Like

Perfect! I am glad it worked out :tada:

I encountered a similar issue, but upon investigation, I discovered that there were multiple identical webhooks in Mautic. After deleting the redundant webhooks and re-saving the published n8n workflow, it began functioning as intended, sending just one email.