CreateAutoScalingGroupRemovalInstanceRule
CreateAutoScalingGroupRemovalInstanceRule
Execution Availability
Try It Out
Submit a mock request using the current auth context and example-driven inputs.
Request Inputs
Body Fields
paramsObjectRequiredRequest body parameter object.
adjustmentTypeStringRequiredThe scale-in method. Options: Remove a specified number of VM instances. Remove VM instances by percentage. Remove VM instances to a specified number.
adjustmentValueIntegerRequiredThe scale-in size.
removalPolicyStringRequiredThe policy for removing a VM instance.
nameStringRequiredThe resource name.
descriptionStringOptional. The detailed description of the resource.
autoScalingGroupUuidStringRequiredThe UUID of the auto scaling group.
typeStringOptional. The type of the auto scaling rule.
cooldownLongOptional. The cooldown time after the auto scaling rule is triggered.
resourceUuidStringOptional. The resource UUID.
tagUuidsListOptional. The tag UUID list.
systemTagsListOptional. The system tags.
userTagsListOptional. The user tags.
Responses
Endpoint
POST/zstack/v1/autoscaling/rules/removal-instance
/zstack/v1/autoscaling/rules/removal-instance
Request Example
curl -X POST 'http://{host}/zstack/v1/autoscaling/rules/removal-instance' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"params":{"adjustmentType":"<adjustmentType>","adjustmentValue":1,"removalPolicy":"<removalPolicy>","name":"<name>","description":"<description>","autoScalingGroupUuid":"<autoScalingGroupUuid>","type":"<type>","cooldown":1,"resourceUuid":"<resourceUuid>","tagUuids":["<tagUuids>"]},"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'
Response Example
200{ "inventory": { "type": "HealthProfile", "description": "just for test", "cooldown": 10.0, "state": "Enabled", "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM", "name": "test-health-policy", "uuid": "f41b2b0ae44637a2af1985e362dc52d4" } }Change History
This API has no change history records yet.
