--- title: "setDesiredCapacity" slug: "compute-autoscaling-setdesiredcapacity" updated: 2026-09-17T10:05:57Z published: 2026-09-17T10:05:57Z canonical: "api.ncloud-docs.com/compute-autoscaling-setdesiredcapacity" --- > ## Documentation Index > Fetch the complete documentation index at: https://api.ncloud-docs.com/llms.txt > Use this file to discover all available pages before exploring further. # setDesiredCapacity ## Overview Set the desired capacity for the specified Auto Scaling Group. ## Request ### Request parameters | Parameter name | Required | Type | Restrictions | Description | | --- | --- | --- | --- | --- | | autoScalingGroupName | Yes | String | Min: 1 Max: 255 | Enter the name of the auto scaling group you want to query. | | desiredCapacity | Yes | Integer | Min: 0 Max: 30 | Set the number of server instances to be operated under that group, based on the expected service capacity. This value must not be less than the existing attribute minSize, which is already set for autoscaling, and must not be greater than maxSize. | | responseFormatType | No | String | | - Format type of the response result Options: xml \| json Default: xml | ## Response ### Response body - [AutoScalingGroupList](/docs/en/common-apidatatype-autoscalinggrouplist) ## Examples ### Request example ``` {AUTOSCALILNG_API_URL}/setDesiredCapacity ?autoScalingGroupName=asg-1 &desiredCapacity=0 ``` ### Response example ``` 9b414c18-0b78-4e8f-a20d-4f95a16628be 0 success 1 asg-1 ***517 lc-1 ***013 0 0 0 slb-1 slb-2 600 SVR Server 2014-02-13T17:24:19+0900 2 zone2 nang zone 3 zone3 nang zone2 ``` ​ ## Errors Errors that may occur while using this action are listed below. For more information about common errors, see [NAVER Cloud Platform API](/docs/en/common-ncpapi-index). | HTTP Response Code | Return code | Return message | | --- | --- | --- | | 400 | 50120 | An invalid or out-of-range value was supplied for the input parameter. | | 400 | 50160 | You cannot delete an Auto Scaling group while there are scaling activities in progress for that group. |