Skip to content

create async mail strapi plugin

We want to be able to send forms with different fields to a Strapi under different domains. The Strapi plugin should store the form data temporarily. A cronjob should send the cached data by email.

Only the backend knows the recipient address of the email. It is configured via dotenv.

We need a controller "async-mail/send", which gets the fields 'from', 'subject' and 'message' and stores them in a collection 'async-mail-outbox'.

A cronjob checks the collection and sends new entries by mail to the recipient configured in dotenv.

A service should enable other modules to also send mails via the async-mail plugin.

A Strapi plugin is to be created, which can be installed via yarn install async-mail@http://github-or-gitlab/repo.

Edited by Carsten Bleek