Update service auto scaling settings
Changed onDEPRECATED. Use PATCH /v1/organizations/{organizationId}/services/{serviceId}/replicaScaling instead. Updates minimum and maximum total memory limits and idle mode scaling behavior for the service. The memory settings are available only for "production" services and must be a multiple of 12 starting from 24GB. Gen 2 (v2-default) services use a fixed size and cannot idle: minTotalMemoryGb must equal maxTotalMemoryGb and idleScaling cannot be true.
Request
- Base URLhttps://api.clickhouse.cloud
- AuthHTTP basic
Path parameters
ID of the organization that owns the service.
ID of the service to update scaling parameters.
Request body
DEPRECATED. Inaccurate for services with non-default numbers of replicas. Use minReplicaMemoryGb instead. Minimum memory of three workers during auto-scaling in Gb. Available only for 'production' services. Must be a multiple of 12 and greater than or equal to 24. Always absent for horizontal-autoscaling services (replica count is variable).
DEPRECATED. Inaccurate for services with non-default numbers of replicas. Use maxReplicaMemoryGb instead. Maximum memory of three workers during auto-scaling in Gb. Available only for 'production' services. Must be a multiple of 12 and lower than or equal to 360 for non paid services or 1068 for paid services. Always absent for horizontal-autoscaling services (replica count is variable).
Number of replicas for the service. The number of replicas must be between 1 and 50. Further restrictions may apply based on your organization's tier and its per-warehouse replica limit. It defaults to 1 for the BASIC tier and 3 for the SCALE and ENTERPRISE tiers.
When set to true the service is allowed to scale down to zero when idle. True by default.
Set minimum idling timeout (in minutes). Must be >= 5 minutes.
Example request
{
"minTotalMemoryGb": 48,
"maxTotalMemoryGb": 360,
"numReplicas": 3
}Response
Successful response
HTTP status code.
Unique id assigned to every request. UUIDv4
Example response
{
"status": 200,
"result": {
"endpoints": [
{
"protocol": "mysql"
}
],
"minTotalMemoryGb": 48,
"maxTotalMemoryGb": 360,
"minReplicaMemoryGb": 16,
"maxReplicaMemoryGb": 120,
"numReplicas": 3,
"minReplicas": 1,
"maxReplicas": 5,
"autoscalingMode": "vertical",
"replicaMemoryGb": 32,
"createdAt": "2026-03-26T20:51:16Z",
"tags": [
{
"key": "Environment",
"value": "staging"
}
]
}
}Changes
- info
added the optional property
result/deletionProtectionto the response with the status
- info