Mailtrain-org / mailtrain

Self hosted newsletter app
GNU General Public License v3.0
5.53k stars 692 forks source link

Recurring / Repeat Campaigns? #611

Closed tiredofit closed 8 months ago

tiredofit commented 5 years ago

Nice work on the rewrite of 2. I previously noticed your 1.x version a few years ago and was scared off by no activity in the repository for a while. I've built a pretty thorough Docker Image (I will share shortly) that does auto configuration for most if not all of the features.

Giving this thing a spin, One of our core needs is an ability to send a recurring weekly campaign (based on RSS - amount of posts within the past "X" days). I can't seem to find out how to configure that setting, nor to set it to continually repeat until forcibly stopped. Is this possible?

bures commented 5 years ago

You mean like a digest of all articles in the RSS feed after N days?

tiredofit commented 5 years ago

Hi thanks for the reponse. Yes, In our usage case We send out mailouts to our learners and parents (Presently just an excerpt of the title, but at some stage would like to send the full content) of everything that happened since the last mailout. Typically this occurs on Tue and Fri depending on the segment.

We let it run for 10 months out of the year, and then pause it.

bures commented 5 years ago

Mailtrain v2 doesn't support this. However I could imagine a an extension that would allow it. We would add another campaign type "Aggregated RSS".

The settings of the campaign would be like for a RSS campaign with these additional fields:

It would mail out a new campaign only if there is at least 1 RSS entry since last mail out.

However, since it would be possible to have multiple RSS entries, the templates would have to be scripted. Thus, when creating a template, one could check whether it is standard template or Handlebars template.

If the Handlebars template is selected (irrespective of the editor), one would have to use Handlebars syntax {{xxx}} instead of the traditional template tags [XXX].

Then, for the Aggregated RSS campaign, the {{rssEntryXXX}} tag (that is the Handlbars equivalent to RSS_ENTRY_*), would be replaced by rssEntries, which would be a list where each item in the list would have the usual RSS_ENTRY_* fields.

That means that somewhere in the template you would something like have:

{{#each rssEntries}}
<img src="{{imageUrl}}"/>
<h3>{{title}}</h3>
<p>{{summary}}<p>
{{/each}}

I'm not sure about whether Mosaico and GrapesJS templates would be possible to do these scripted Handlebars templates. I guess that for Mosaico it should be possible on the level of "Mosaico Template" definition, which is specified in a code editor. You should definitely be able to create a template in the regular HTML or MJML code editor.

So the big question is - does it address your use case? And most importantly, would you have enough technical knowledge to use it?

tiredofit commented 5 years ago

I follow you completely on this. What you have identified for us to handle in terms of template creation would be certainly possible. I have a developer who would be able to figure out the templates and out one together by hand if need be. Provided that it would be easy to choose the Aggregated RSS option similar to the other 3 options available would make it very clear for our Communications team (who I would say have a technical skill level of 3/10) to be able to get their work doene. I'm just the lowly Director who has Docker skills which is where I come in :)

The only thing I might point out that would be needed, and I'm not sure if it is covered with the "Weekly" schedule would be to set multiple days per week to launch the Aggregated Campaign, ie set it up to fire on both Monday And Wednesday throughout the week as opposed to just a single day. We're an educational non profit and stagger our mailouts to various audiences throughout the week and sometimes we have postings on the 2nd run, sometimes not. Presently we use a php based list manager which supports this sort of feature, but is highly erratic with its mailing and the communications team has lost confidence. I've already proven in a few days that MailTrain v2 beta far exceeds the quality of the other tool and hooking into the API has been a dream come true.

tiredofit commented 5 years ago

Just checking in on this again, is this still something in the development pipeline? We'd be willing to offer a donation to the project for this to be in place. My communciations team are getting antsy and wanting to head to a hosted service, and I'm trying to beat them at the pass :)

martinmurciego commented 4 years ago

Nobody has how to do this to configure the weekly sending of all new entries so as not to send every so often? How does a newsletter not send a summary of entries periodically? Without this functionality they cannot compete.

talheim-it commented 8 months ago

We are going to start with the development and testing of mailtrain v3 in the next weeks.

You are welcome to help us with the testing as soon as the first release candidate is available.