exp:mailbounces
Available since Exponential 6.0.15 (in development, not in a release yet).
Summary
Read the bounce mailbox: hard bounces and spam complaints go on the suppression list (dry run unless --apply)
Usage
./console exp:mailbounces [options] php bin/php/mailbounces.php [options] ./console exp:mail:bounces [options]
Aliases
exp:mail:bounces
Help
The output of ./console help exp:mailbounces (the script run with --help), without the standard options:
Usage: bin/php/mailbounces.php [OPTION]... Bounce mailbox Reads the mailbox of mailpreferences.ini [BounceSettings] (IMAP or POP3, set in a settings override): hard bounces (delivery status notifications with a permanent failure of HardStatusCodes[]) and spam complaints (feedback loop reports) put the address on the suppression list. Soft bounces and other mail are counted only. No address is shown in full. Without --apply nothing is changed: the messages are read and reported, no address is suppressed, no message is marked or deleted and the status is not written. --dry-run is still accepted and means the same as no flag; --apply together with --dry-run is a usage error (exit 2). ./console exp:mail:bounces show what reading the mailbox would do ./console exp:mail:bounces --apply read the mailbox and suppress the addresses ./console exp:mail:bounces --file=dsn.eml read saved messages (a file or a directory of .eml) ./console exp:mail:bounces --status the last run Ends with PASS, SKIP (the reader is disabled or not configured) or FAIL (exit 1). Options: --apply Suppress the addresses, handle the messages and write the status (the default is a dry run) --dry-run The default, kept for scripts that pass it: report only, nothing is suppressed, no message is changed, the status is not written --file=VALUE Read these saved messages (.eml file, or a directory of them) instead of the mailbox --status Show the last run and stop --json One JSON object instead of the text
Options
| Option | Value | Description |
|---|---|---|
| --apply | - | Suppress the addresses, handle the messages and write the status (the default is a dry run) |
| --dry-run | - | The default, kept for scripts that pass it: report only, nothing is suppressed, no message is changed, the status is not written |
| --file | required | Read these saved messages (.eml file, or a directory of them) instead of the mailbox |
| --status | - | Show the last run and stop |
| --json | - | One JSON object instead of the text |
Standard options
Every script also takes the standard options of the script framework: --help, --quiet, --siteaccess, --debug, --colors, --no-colors, --logfiles, --no-logfiles, --verbose and --allow-root-user.
Source
bin/php/mailbounces.php, kernel/private/classes/commands/mailbounces.php
See also
Generated example: exp:mailbounces
Added to the reference for Exponential 6.0.15.
Contributors
- Graham Brookins Updated
Comments
Add a comment