Description
This function deletes an email account. When you call this function, the system deletes the email account and all of its data.
Warning:
We strongly recommend that you use the following UAPI function instead of this function:
-
Email::delete_pop
— This function deletes an email address.
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 |
domain |
string |
Required The email account's domain. |
A valid domain on the cPanel account. For example, example.com to deleteuser@example.com. |
example.com |
|
string |
Required The email account's username. |
An email account username. For example, user to delete user@example.com |
user |
Returns
Return |
Type |
Description |
Possible values |
Example |
rawout |
string |
A confirmation message. |
A message that the function successfully removed the email account's Horde data. |
\nHorde data for \u201cuser@example.com\u201d has been removed.\n\n\n |
reason |
string |
A message of success or a reason for failure. |
|
This is an error message. |
result |
Boolean |
Whether the function succeeded. |
|
1 |