Run multiple WHM API 1 functions
This function combines calls for multiple WHM API 1 functions.
Query parameters
The WHM API 1 function to call.
Important:
Specify a command parameter for each function.
Note:
Include the function's input parameters as a URI-encoded list after the function name. For example, to call the killdns function with a domain parameter value of example.com directly you would use:
killdns?domain=example.com
To call this function using the batch function, URI-encode the command and pass it as part of the batch function:
/json-api/batch?api.version=1&command=killdns%3Fdomain%3Dexample.com
You can call the same function multiple times within a single batch API call. For example:
/json-api/batch?api.version=1&command=version&command=version&command=version
Whether to stop processing remaining commands in the batch when a command returns an error.
- 1 — Do not process remaining commands in the batch when an error occurs.
- 0 — When an error occurs, process the remaining commands in the batch.
Response
HTTP Request was successful.
Example response
{
"data": {
"result": [
{
"data": {
"hostname": "example-hosting.com"
},
"metadata": {
"command": "gethostname",
"reason": "OK",
"result": 1,
"version": 1
}
},
{
"data": {
"version": "11.88.0.1"
},
"metadata": {
"command": "version",
"reason": "OK",
"result": 1,
"version": 1
}
}
]
},
"metadata": {
"command": "batch",
"reason": "OK",
"result": 1,
"version": 1
}
}