Delete email address

This function deletes an email address.

Important:

When you disable the Receive Mail role, the system disables this function.

SecurityBasicAuth
Request
query Parameters
required
string or string

The email account username or address.

  • A valid email account username. For example, user if the email address is user@example.com.
  • A valid email address.
Example: email=user@domain.com
domain
string <domain>
Default: "The cPanel account's main domain."

The email account's domain. For example, example.com if the email address is user@example.com.

Example: domain=example.com
flags
string

Whether to remove the mail account's home mail directory. If you do not specify a value, the function removes the mail account's home directory.

  • passwd — Preserve the mail account's home directory.
  • Any other value — Remove the mail account's home directory.
Example: flags=passwd
skip_quota
integer
Default: 0

Whether to modify the mail account's quota file.

  • 1 — Do not modify.
  • 0 — Modify.
Enum: 0 1
Example: skip_quota=0
Responses
200

HTTP Request was successful.

Response Schema: application/json
apiversion
integer

The version of the API.

func
string

The name of the method called.

module
string

The name of the module called.

object
get/Email/delete_pop
Request samples
uapi --output=jsonpretty \
  --user=username \
  Email \
  delete_pop \
  email='user@domain.com'
Response samples
application/json
{
  • "apiversion": 3,
  • "func": "delete_pop",
  • "module": "Email",
  • "result": {
    • "data": null,
    • "errors": null,
    • "messages": null,
    • "metadata": { },
    • "status": 1,
    • "warnings": null
    }
}