Description
This function tests mail filters. The function only tests filters for the cPanel account's main domain, and only tests against the message's body.
For more information about Exim filters, read Exim's documentation.
Note:
In cPanel & WHM version 11.50 and later, if the domain or account does not contain a filter file, this function will fail.
Examples
Note:
Use cPanel's API Shell interface (Home >> Advanced >> API Shell) to directly test cPanel API calls.
Parameters
Parameter |
Type |
Description |
Possible values |
Example |
account |
string |
The email address, to test legacy cPanel filters in the filtersdirectory. If you do not use this parameter, the function tests the main domain's filters in the /etc/vfilters directory. |
A valid email address on the account. |
user@example.com |
msg |
string |
Required The string to test. The function uses this string as the body of an email message, to check whether filters would match the string. |
A string. |
Test |
Returns
Return |
Type |
Description |
Possible values |
trace |
string |
A series of messages that describe the trace results. |
A series of strings. Note: This output may contain HTML. |