1

If we make a "Print shipping label" for several shipments at once, then Magento sends "Shipment Email" to all these customers at once.

The terms of our service provider do not allow multiple emails to be sent in a second, and they have recently blocked us from sending emails from the server for this reason. Cause: To ensure consistent quality and stability of the service, it is allowed to send 1 message from the virtual server every 5 seconds.

Is it possible to change "Shipment Email" settings so that emails are sent out one by one with a 5-second delay?

2 Answers 2

0

If you are sending the emails via cronjob, then you could override the cron schedule value in vendor/magento/module-sales/etc/crontab.xml

This is the section that contains the shipment emails:

<job name="sales_send_order_shipment_emails" instance="SalesShipmentSendEmailsCron" method="execute">
    <schedule>* * * * *</schedule>
</job>
0

If you want to send emails one by one and after some time interval then you need to us e consumer queue

https://devdocs.magento.com/guides/v2.4/config-guide/mq/manage-message-queues.html

and in database table you need to create flag colum for shipment email has sent.

Hope this will help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.