v1

latestOpenAPI 3.0.2cPanel License2026-08-06657427.1 MB
Email
Email Forwarding

Create domain-level forwarder

This function creates a domain-level forwarder.

Important:

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

get/Email/add_domain_forwarder

Query parameters

destdomainstring domain required
Example:forwardtome.com

The domain to receive forwarded mail.

domainstring domain required
Example:example.com

The domain on the cPanel account from which to forward mail.

Response

HTTP Request was successful.

apiversioninteger

The version of the API.

funcstring

The name of the method called.

modulestring

The name of the module called.

Example response

{
  "apiversion": 3,
  "func": "add_domain_forwarder",
  "module": "Email",
  "result": {
    "data": "File updated \"/etc/vdomainaliases/example.com\"",
    "status": 1
  }
}