UAPI accesses the cPanel interface's features. Use this API to access and modify cPanel account data and settings.
https://api.docs.cpanel.net/_mock/specifications/cpanel.openapi/
https://{host}:{port}/execute/
Request
This function deletes an email forwarder.
Important:
When you disable the Receive Mail role, the system disables this function.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/cpanel.openapi/Email/delete_forwarder
- A server running cPanel.
https://cpanel-server.tld:2083/execute/Email/delete_forwarder
- CLI
- URL
- curl
- JavaScript
- Node.js
- Python
- Java
- Java8+Apache
- C#
- C#+Newtonsoft
- PHP
- Go
- Ruby
- R
uapi --output=jsonpretty \
--user=username \
Email \
delete_forwarder \
address='user@example.com' \
forwarder='fwdtome@example.com'{ "apiversion": 3, "func": "delete_forwarder", "module": "Email", "result": { "data": null, "errors": null, "messages": null, "metadata": {}, "status": 1, "warnings": null } }
Request
This function lists domain-level forwarders.
Important:
When you disable the Receive Mail role, the system disables this function.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/cpanel.openapi/Email/list_domain_forwarders
- A server running cPanel.
https://cpanel-server.tld:2083/execute/Email/list_domain_forwarders
- CLI
- URL
- curl
- JavaScript
- Node.js
- Python
- Java
- Java8+Apache
- C#
- C#+Newtonsoft
- PHP
- Go
- Ruby
- R
uapi --output=jsonpretty \
--user=username \
Email \
list_domain_forwarders{ "apiversion": 3, "func": "list_domain_forwarders", "module": "Email", "result": { "data": [ … ], "errors": null, "messages": null, "metadata": { … }, "status": 1, "warnings": null } }
Request
This function lists a domain's forwarders.
Important:
When you disable the Receive Mail role, the system disables this function.
A Perl Compatible Regular Expression (PCRE) that filters the results. If you do not use this parameter, the function returns results for all of the account's filters.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/cpanel.openapi/Email/list_forwarders
- A server running cPanel.
https://cpanel-server.tld:2083/execute/Email/list_forwarders
- CLI
- URL
- curl
- JavaScript
- Node.js
- Python
- Java
- Java8+Apache
- C#
- C#+Newtonsoft
- PHP
- Go
- Ruby
- R
uapi --output=jsonpretty \
--user=username \
Email \
list_forwarders \
domain='example.com'{ "apiversion": 3, "func": "list_forwarders", "module": "Email", "result": { "data": [ … ], "errors": null, "messages": null, "metadata": { … }, "status": 1, "warnings": null } }