WHM API.
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/
https://{host}:{port}/json-api/
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/ea4_get_additional_pkg_prefixes
- A server running WHM.
https://whm-server.tld:2087/json-api/ea4_get_additional_pkg_prefixes
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/ea4_get_additional_pkg_prefixes{ "data": { "additional_pkg_prefixes": [ … ] }, "metadata": { "command": "ea4_get_additional_pkg_prefixes", "reason": "OK", "result": 1, "version": 1 } }
Request
This function returns a list of the currently-installed EasyApache 4 packages.
Important:
When you disable the Web Server role, the system disables this function.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/ea4_get_currently_installed_packages
- A server running WHM.
https://whm-server.tld:2087/json-api/ea4_get_currently_installed_packages
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/ea4_get_currently_installed_packages{ "data": { "packages": [ … ] }, "metadata": { "command": "ea4_get_currently_installed_packages", "reason": "OK", "result": 1, "version": 1 } }
Request
This function returns a list of all EasyApache 4 profiles and the packages that each profile provides.
Important:
When you disable the Web Server role, the system disables this function.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/ea4_list_profiles
- A server running WHM.
https://whm-server.tld:2087/json-api/ea4_list_profiles
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/ea4_list_profiles{ "data": { "cpanel": [ … ], "custom": [ … ], "property1": [ … ], "property2": [ … ] }, "metadata": { "command": "ea4_list_profiles", "reason": "OK", "result": 1, "version": 1 } }