Merge Contacts via API

Your software
My Mautic version is: 4.4.2
My PHP version is: 7.4
My Database type and version is: MySQL 8

Your problem
My problem is:

I’m searching for a way to merge Mautic contacts via API request. My users don’t interact directly with Mautic forms, but with my SaaS application and marketing site. Because of this, I need a way to tell Mautic who the contact is, and if they already exist in the system, to merge the contact that was just created with another specific Mautic contact.

Specifically, if an anonymous visitor is identified by the marketing site or application, I want to tie that anonymous user back to the Mautic contact.

I’ve searched through the documentation but haven’t found a clear answer on how to do this.

I had thought that passing an email address in the request that already exists might help, but sadly no luck. When I tried this, I was referencing this page of the documentation: https://docs.mautic.org/en/contacts/manage-contacts/contact-monitoring

Any insight anyone may have would be appreciated.

Sounds like this does something that you might be interested in: < Mautic Developer Documentation >.

If that is not enough for some reason you can search for every contact and trigger appropricate action based on what the results are (if contact exists or not).

1 Like

This how I solved the issue, not elegant but it works.

Essentially out a mautic form on your redirect page after they complete your lead form. Have the mautc form auto populate with the data from the lead form by passing the parameters via url. Then make he mautic form auto submit itself, finally hide the mautic form. That way it’s the same as if the lead completed a mautic form and you get all the associated coll functions long with that.

2 Likes