How to add contacts from CSV automatically in a segment

Your software
My Mautic version is: 3.2.0
My PHP version is:7.2.
My Database type and version is:

Your problem
My problem is: I want to add some contacts with fields: name, country, email. When im importing them and manually add the segment they goes in it with no problem. But when i added them and create a rule in the segment (geo based rule and/or tag based rule) they cant go in the right segment. My question is: how to automatically distribute the contacts to the segments? Via cron jobs or API or combination of both and is it possible at all? I need something like this: contacts from a.csv goes to “a” segment, contacts from b.csv goes to “b” segment even when the CSV files are updates with new contacts I want them go automatically into the right segments. Thank you !

These errors are showing in the log:

Steps I have tried to fix the problem:

API is probably the best way to do it, otherwise you can setup cronjob and use the Custom Import plugin to do this for you.

You also need to make sure that your segment update cronjob are running consistently.

You can find the Custom Import plugin here.

2 Likes

but its totally possible and i dont need to use mautic forms - i can add contacts in my own database and send it to Mautic’s segments via API or this plugin + cron jobs?

hi yes this is correct …

1 Like