How to send follow-up emails to targets who have not yet replied?

Hello,

I’m just getting started with SuiteCRM and exploring its functions - I like it so far! But I have a question about automating email campaigns (using Workflows or otherwise).

What I want to achieve:

  1. Send emails based on my email template to a list of prospects (‘targets’) - let’s call it list A
  2. Wait for a while, let’s say 2 weeks
  3. Send new emails based on another email template (follow-up emails) to the same target list except for those who have responded. If we denote repondents as R, then I want to be able to target a new list B = A / R.

How do I achieve it?
Is it possible to do with the builtin functionality of SuiteCRM, or should I look into implementing custom modules?

With kind regards,
Eric

If you can build a new target list with just the ones who replied, then you can use that as a “suppression list” and re-send the campaign to the original list. The ones in the suppression list won’t be sent.

Another strategy is to make a target list with just the ones you want to send the second time. Have a look at the feature that lets you dump a Report (Reports module) as a Target List - this is quite a powerful way to filter and select.

1 Like

Thank you for the suggestions!

Is there a built-in way of filtering target lists by ‘has replied’ criteria? I think any of the suggested solutions would work as long as there is a way to filter target lists based on whether they’ve replied to an email or not.

I tried looking into Reports Module and there seems to be a way to set up conditions for Email status == ‘Replied’, but I didn’t manage to get it to work so far.

My guess is that this ‘Replied’ status is only detected for emails authored by a user (admin or any of the registered SuiteCRM users), but what I want to achieve is to make sure the system detects email replies properly.

There’s probably a better field/attribute for filtering prospects based on their response, no? Perhaps I’m missing a simple (and intended) solution?

P.S.: In case if that matters, I have full control over the setup, so if there are any specific requirements for Outgoing Email / SMTP / Bounce handling email

I’m sorry, but I don’t really have an answer for you at that level of detail. I am not sure of what constitutes the “has replied” condition internally, in SuiteCRM.

I can perhaps give you a suggestion: you can have a Workflow react to some event (a new email, for example) and test a few conditions and set a simple boolean flag (my_has_replied) in the record. Then you can use that flag in the Report (or directly in a List view filter, which you can also use to Add to Target List.

Good luck, and tell us how you did it, if you succeed :slight_smile:

1 Like

It’s taken me a very long time to start figuring out how to get to the solution, and at some point I figured that inbound emails are not getting saved (imported) into the database properly.
As it turned out the issue was due to multiple inbound emails conflicting with each other (i.e. I had defined both a bounce handler and a personal email account for the same email).
So I ensured there’s only one inbound email box defined for my email address, and now the inbound emails are getting imported properly into the system.

With this now I’m able to generate reports on Emails module, but feeling lost in all the different fields that can be added to the reports… For example, what is Emails > Emails:Prospect > Campaign LogProspect List ID field? Trying to figure out if the system is smart enough to match inbound email’s “From” field with prospects.

If that’s the case, I’m confused about how the system tells which of the Prospect List’s to match the inbound emails to (assuming Prospect List is just another term for Target List, and that one Prospect may be included in different Prospect List’s)

Any hints would be of big help (to help me wrap my mind around this)!

After a long series of trials and errors I managed to get it to work. Thanks to @pgr for the ideas - I used them partially in my solution.

I ended up doing the following:

  1. Set up a bounce-handling email account with auto-import option turned on (so that email hooks get triggered for each incoming message)
  2. Define a custom logic hook for Emails module (as a file under /custom/Extension/modules/Emails/Ext/LogicHooks/) which gets triggered on after_save event;
  3. The hook extracts “From” email address of the incoming email and looks up the prospect(s) with this email and marks them not to be disturbed again by adding them to the corresponding Suppression lists of the email campaigns they have previously been a part of.

Although not a perfect solution, it does exactly what I wanted it to :slight_smile:

I’ll leave some useful code fragments here.

How to retrieve a list of all records (beans) with given email address?

$from_email = '<your_email_address_here>';
$sea = new SugarEmailAddress();
$beans = $sea->getBeansByEmailAddress( $from_email );

You can further filter the $beans array by the object type you need (e.g. $bean instanceof Prospect).

How to create a new ProspectList for a given Campaign?

// map $campaign_id to the actual Campaign object
$campaign = BeanFactory::getBean( 'Campaigns', $campaign_id );
// ensure prospect lists data is loaded for this campaign
$campaign->load_relationship( 'prospectlists' );

// Create a new prospect list
$prospect_list = new ProspectList();
$prospect_list->name = '<some name here, e.g. $campaign->name . "some_suffix"';
$prospect_list->assigned_user_id = $assigned_user_id;
$prospect_list->list_type = "default"; // either 'default', 'test' or 'exempt'
$prospect_list->save();
// Add this list to the campaign
$campaign->prospectlists->add($prospect_list->id);

I hope this saves some time for someone who comes across this post.
It helped me to read not only SuiteCRM’s documentation but also the docs of its commercial version (SugarCRM):
https://support.sugarcrm.com/Documentation/Sugar_Developer/Sugar_Developer_Guide_9.0/Data_Framework/Models/SugarBean/

2 Likes

Thanks for coming back and writing up these instructions, I’m sure they will be useful for someone in the future :+1:

Hi Eric,

I have not used suitecrm yet, installed it for quite some time, but still didn’t do anything with it. I wanted to contact influencers for a website launch, as @#$@#$ gmail/outlook is putting emails from small providers into spam by default, I wanted to adapt your procedure to something like this

  • try to get their email via instagram/facebook etc
  • send them email based on email template
  • wait for a while
  • send reminder to who did not respond or who I am missing info of (follow-up emails)

Is there no way I can do this with a default suitecrm7 and without coding? Seems a bit strange to me to have workflows based on a predetermined schedules instead of events occurring or not occurring.

[1]