Mail Archive

Mail Archive

by Friends of Shopware


Archives outgoing Shopware 6 emails and enables centralized access to sent message content directly in the Shopware Administration.

This plugin is compatible with the following Shopware 6 versions:

6.6 6.7
  • Future updates
  • MIT license

Mail Archive is the official open-source plugin developed by Friends of Shopware. It archives outgoing Shopware 6 emails in the database and makes them available directly within the Shopware Administration. This allows administrators to review, search, and resend previously sent messages whenever required.

Centralized email archiving simplifies customer communication tracking and helps merchants, support teams, and developers maintain a complete history of outgoing emails.

Key Features at a Glance

  • Archives all outgoing Shopware emails.
  • Stores email attachments together with archived messages.
  • Links archived emails to the corresponding customer.
  • Resend archived emails directly from the Shopware Administration.
  • Download archived emails in EML format.
  • Built-in search for quickly locating archived messages.
  • Seamless integration into the Shopware Administration.
  • Open-source extension for Shopware 6.

Mail Archive is an excellent choice for merchants, agencies, support teams, and developers who want to centrally archive outgoing emails and simplify communication tracking.

Open Source and License Notice

This plugin is based on the open-source project Mail Archive by Friends of Shopware and is distributed through our platform. Unless stated otherwise, this plugin is provided under the terms of the MIT License. The original copyright notice and the full license text are included in the plugin package.

Copyright (c) Friends of Shopware

The software is provided "as is", without warranty of any kind, to the extent permitted by applicable law. The terms of the MIT License shall prevail. You can find the full license text in the plugin package and at: https://github.com/FriendsOfShopware/FroshPlatformMailArchive/blob/main/LICENSE.md.

Source: Github Repository


Changelogs

Archived mails can now be deleted from the administration again. Deletion removes the archive, its attachments, and the stored EML file, while inserts and updates remain restricted to the system scope.

Fixed

  • Allowed archive deletion through the administration while retaining write protection for creating and updating archived mails. Deletion controls are governed by the new frosh_mail_archive:delete privilege, and failures now display the API error detail or a fallback message (#164, @shyim).

Full Changelog: https://github.com/FriendsOfShopware/FroshPlatformMailArchive/compare/3.8.2...main

No user-facing changes.

The administration build now resolves the plugin’s relative ESM imports correctly on Shopware 6.6.

Fixed

  • Added explicit .js filenames to administration imports, fixing builds that failed when Shopware 6.6’s strict ESM resolver encountered extensionless file and directory imports (#162, @shyim).

Full Changelog: https://github.com/FriendsOfShopware/FroshPlatformMailArchive/compare/3.8.0...main

The mail detail page now shows the CC and BCC recipients of archived mails, old archive entries can be cleaned up from the console, and bulk resends no longer fail on mailers with a concurrent connection limit.

Added

  • CC and BCC recipients are shown in the mail detail metadata, read from the stored .eml file, so no schema change or migration is required. Mails without those headers display -; mails archived without an EML file (or whose EML cannot be read) simply show no values. The data comes from a new Administration endpoint (POST /api/_action/frosh-mail-archive/fetch-eml-headers) that requires the archive read permission, so users with view access see it too. (#160, @shyim)

  • New console command to trigger the mail archive cleanup on demand:

    bin/console frosh:mail-archive:cleanup
    

    The command queues the cleanup as a message and returns immediately; archived mails and their .eml files are deleted when the message queue worker processes it, which makes the run observable from cron monitoring tools such as Oh Dear. Retention is still controlled by "Automatically delete emails older than specified days" in the plugin configuration (0 disables deletion). The daily scheduled task now uses the same message and handler. (#119, @wannevancamp)

Fixed

  • Bulk resend from the listing sends the selected mails one after another instead of all at once, so mailers with a concurrent connection limit no longer reject the batch with a 400 Bad Request. If a send fails, the remaining mails are skipped and an error notification is shown, while the selection is reset, the listing refreshed and the loading indicator cleared. Mails are therefore sent slightly slower than before. (#116, @Niebvelungen)

New Contributors

  • @wannevancamp made their first contribution in #119
  • @Niebvelungen made their first contribution in #116

Full Changelog: https://github.com/FriendsOfShopware/FroshPlatformMailArchive/compare/3.7.1...main

  • Fixed Orders/Customers cannot be deleted due to foreign key error

  • Added a "sent date from" and "sent date to" filter to the mail archive listing (#151)
  • Added a resend dialog that lets you change the recipients before an archived mail is sent again (#153)
  • Added mail archive permissions to the Administration role settings with viewer, editor (resend) and attachment permissions (#154)
  • Renamed the resend privilege from frosh_mail_archive:update to frosh_mail_archive:resend, existing roles need this permission reassigned (#155)
  • Replaced the placeholder of "delete mails after days" with a help text and rejected values below 0, use 0 to disable automatic deletion (#155)
  • Reworked the mail detail view with a responsive two-column metadata layout and moved the resend history below the mail content (#155)
  • Sanitized the HTML and plain text preview and added a restrictive content security policy, so external content and scripts no longer load (#155)
  • Raised the required zbateson/mail-mime-parser version to ^3.0.6 (#155)
  • Fixed Microsoft Graph dropping archived mails by sending the message ID as valid X-Frosh-Message-ID header, the old header is still read (#149)
  • Fixed duplicate attachment entries when the same transport event is processed more than once (#152)
  • Fixed resending a mail keeping the original To, Cc and Bcc recipients on top of the new ones (#155)
  • Fixed Shopware 6.8 deprecations by moving services.xml to services.yaml and replacing EntitySearchResult::first() (#150)
  • Fixed the cleanup task failing on mails without a valid .eml path and validate the mail ID before writing archive files (#155)
  • Secured the archive, resend and attachment API endpoints with the plugin ACL permissions (#155)
  • Protected archived mails and attachments with system-scope write protection, so Administration users can no longer modify or forge archive entries (#155)
  • Hidden the resend and bulk actions in the Administration for users without the resend permission (#155)

  • chore: prepare release 3.6.0
  • fix: added column and table exists checks (#141)
  • feat: store mail template id (#140)
  • feat: make label of config clearer (#134)