✨ Introduce configurable sending quotas #955
Open
+298
−7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.



This pull request introduces configurable SMTP quota limits at both the global (settings), user, and alias levels, allowing administrators to restrict the number of emails sent per hour and per day. It adds support for these limits in the backend, exposes them via a new API endpoint, and updates the admin UI and translations accordingly. Comprehensive tests are included to ensure correct behavior.
SMTP Quota Limit Functionality
smtp_quota_limit_per_hourandsmtp_quota_limit_per_day, including validation and display in the settings UI. [1] [2] [3]UserandAliasentities to support custom SMTP quota limits, with corresponding getter/setter methods and database mapping. [1] [2] [3] [4]SmtpQuotaLimitsTypefor editing quota limits, and integrated it into the admin forms for users and aliases. [1] [2] [3] [4] [5]API and Backend Enhancements
/api/postfix/quota/{email}to retrieve the effective SMTP quota limits for a user or alias, defaulting to global settings if no custom limits are set. [1] [2] [3]