Update NGINX caching status.

This function enables or disables NGINX caching.

SecurityBasicAuth
Request
query Parameters
enabled
required
integer

Whether to enable to disable caching.

Note:

  • 1 - Enables caching.
  • 0 - Disables caching.
Enum: 1 0
Example: enabled=1
user
Array of strings <username>
Default: []

A list of users whose caching you want to enable or disable.

Note:

If you do not pass this parameter, this function sets the caching status for all users on the system.

Example: user=unclebob&user=auntsue
Responses
200

HTTP Request was successful.

Response Schema: application/json
object
get/nginxmanager_set_cache_config
Request samples
whmapi1 --output=jsonpretty \
  nginxmanager_set_cache_config \
  enabled='1'
Response samples
application/json
{
  • "metadata": {
    • "command": "nginxmanager_set_cache_config",
    • "reason": "OK",
    • "result": 1,
    • "version": 1
    }
}