WPX
Return WordPress installation
Changed onThis function returns a single WordPress installation, addressed by its numeric WordPress Toolkit instance id parameter. The returned row is identical to one element of the list_websites response, so the same consumer mapping works for both.
Note:
- This is a lightweight by-id read intended for resolving one installation directly, without listing every installation. A direct lookup is not subject to the brief eventual-consistency lag that can keep a freshly created installation out of list_websites.
- A valid id parameter that does not exist, or that belongs to another account, is not an error: the call succeeds with an empty (null) data field. An installation owned by another account is indistinguishable from one that does not exist.
- A missing or non-integer id parameter, or a backend failure, returns a failure status with a message in the errors field.
get/WPX/get_website
Request
- Base URLhttps://cpanel-server.tld:2083/execute
- AuthHTTP basic
Query parameters
idinteger required
The WordPress Toolkit installation id, as returned in the wptk_id field of list_websites.
Response
HTTP Request was successful.
Example response
{
"apiversion": 3,
"func": "get_website",
"module": "WPX",
"result": {
"data": {
"admin_url": "https://blog.example.com/wp-login.php",
"alive": 1,
"documentroot": "/home/user/public_html",
"domain": "blog.example.com",
"title": "My Blog",
"url": "https://blog.example.com",
"version": "6.4.2",
"wptk_id": 17
},
"metadata": {
"transformed": 1
},
"status": 1
}
}Changes
- info
endpoint added
- info