WHM API.
Download OpenAPI description
Overview
URL
WebPros International, LLC
License
Languages
Servers
Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/
A server running WHM.
https://{host}:{port}/json-api/
Request
This function evaluates and validates an Exim configuration file's syntax.
Note:
On servers that run CentOS 7, you may see a named warning about the absence of SPF resource records on DNS.
- This warning is not relevant on CentOS 7 servers, because RFC 7208 deprecated SPF records. CentOS 7 servers use TXT records instead of SPF records.
- Red Hat 7.1 and CentOS 7.1 both contain
bind-9.9.4-23.el7, which is an updated version of BIND that complies with RFC 7208. To resolve this issue, update your operating system to a version that contains the updated version of BIND. For more information, read the Red Hat Bugzilla case about SPF record errors.
Security
BasicAuth
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/validate_exim_configuration_syntax
- A server running WHM.
https://whm-server.tld:2087/json-api/validate_exim_configuration_syntax
- CLI
- URL
- curl
- JavaScript
- Node.js
- Python
- Java
- Java8+Apache
- C#
- C#+Newtonsoft
- PHP
- Go
- Ruby
- R
whmapi1 --output=jsonpretty \
validate_exim_configuration_syntaxResponse
application/json
{ "command": "validate_exim_configuration_syntax", "data": { "broken_cfg_html": "RAW_CONFIGURATION_TEXT", "broken_cfg_text": "==>RAW_CONFIGURATION_TEXT<==\n", "error_line": 1, "error_msg": "This is an error message." }, "output": { "raw": "\n" }, "reason": "OK", "result": 1, "version": 1 }
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/disable_mail_sni
- A server running WHM.
https://whm-server.tld:2087/json-api/disable_mail_sni
- CLI
- URL
- curl
- JavaScript
- Node.js
- Python
- Java
- Java8+Apache
- C#
- C#+Newtonsoft
- PHP
- Go
- Ruby
- R
whmapi1 --output=jsonpretty \
disable_mail_sni \
domain='example.com'Response
application/json
{ "data": {}, "metadata": { "command": "disable_mail_sni", "reason": "cPanel & WHM no longer allows mail SNI to be disabled.", "result": 0, "version": 1 } }