WHM API.
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/
https://{host}:{port}/json-api/
Request
This function returns the cPanel API 1 functions that the system called on specific dates. This is useful, for example, to check whether your system calls any cPanel API 1 functions.
Important:
The function only returns cPanel API 1 functions. We deprecated cPanel API 1 and plan to remove those functions at a later date. For more information, read our Guide to Replacing cPanel API 1 Functions with UAPI Equivalents documentation.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/get_api_calls
- A server running WHM.
https://whm-server.tld:2087/json-api/get_api_calls
- 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/get_api_calls?type=cpapi1'{ "data": { "result": [ … ] }, "metadata": { "command": "get_api_calls", "reason": "OK", "result": 1, "version": 1 } }
Request
This function returns the daily interface use of cPanel API 1 functions. Use this function to find out which API calls your custom interfaces or third-party plugins use.
Important:
The function only returns cPanel API 1 functions. We deprecated cPanel API 1 and plan to remove those functions at a later date. For more information, read our Guide to Replacing cPanel API 1 Functions with UAPI Equivalents documentation.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/get_api_pages
- A server running WHM.
https://whm-server.tld:2087/json-api/get_api_pages
- 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/get_api_pages?type=cpapi1'{ "data": { "count": 200000, "entry": "/usr/local/cpanel/base/frontend/jupiter/plugin1/index.html.tt", "timestamp": 1548828000 }, "metadata": { "command": "get_api_pages", "reason": "OK", "result": 1, "version": 1 } }