All Products
Search
Document Center

Enterprise Distributed Application Service:ModifyScalingRule

Last Updated:Oct 12, 2026

Modifies the auto scaling rules.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

edas:ManageApplication

update

*Application

acs:edas:{#regionId}:{#accountId}:namespace/{#NameSpaceId}/application/{#AppId}

None None

Request syntax

POST /pop/v5/app/scaling_rules HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

AppId

string

Yes

The application ID.

74ee****-db65-4322-a1f6-bcb60e5b****

GroupId

string

Yes

The deployment group ID.

8123db90-880f-486f-****-************

InCondition

string

No

The trigger condition. Valid values:

  • OR: Any condition.

  • AND: All conditions.

Valid values:

  • OR :

    Any condition is met.

  • AND :

    All conditions are met.

"OR"

InEnable

boolean

No

Specifies whether to include the scale-in rule. Valid values:

  • true: Included.

  • false: Not included.

true

InCpu

integer

No

The trigger metric: CPU utilization.

50

InDuration

integer

No

The duration, in minutes.

50

InInstanceNum

integer

No

The minimum number of instances to retain when the group scales in.

3

InLoad

integer

No

The trigger metric: system load.

50

InRT

integer

No

The trigger metric: service latency. Unit: milliseconds. Minimum value: 0.

50

InStep

integer

No

The number of instances to scale in at a time.

1

OutCondition

string

No

The trigger condition. Valid values:

  • OR: Any condition.

  • AND: All conditions.

Valid values:

  • OR :

    Any condition is met.

  • AND :

    All conditions are met.

"OR"

OutCPU

integer

No

The trigger metric: CPU utilization.

50

OutDuration

integer

No

The duration, in minutes.

50

OutEnable

boolean

No

Specifies whether to include the scale-out rule.

true

OutInstanceNum

integer

No

The maximum number of instances when the group scales out.

10

OutLoad

integer

No

The trigger metric: system load.

50

OutRT

integer

No

The trigger metric: service latency. Unit: milliseconds. Minimum value: 0.

0

OutStep

integer

No

The number of instances to scale out at a time.

0

ResourceFrom

string

No

The source of instances for scale-out. Valid values:

  • NEW: Elastic resources.

  • AVAILABLE: Existing resources. To prioritize existing resources, use AVAILABLE_FIRST.

If you set this parameter to NEW or AVAILABLE_FIRST, you must specify auto scaling parameters. Auto scaling includes two modes: launch template and existing instance rule.

Valid values:

  • AVAILABLE :

    Existing resources.

  • NEW :

    Elastic resources.

  • AVAILABLE_FIRST :

    Prioritize existing resources.

"AVAILABLE"

MultiAzPolicy

string

No

The multi-zone scaling policy for auto scaling. Valid values:

  • PRIORITY: Priority policy.

  • BALANCE: Balanced distribution policy.

Valid values:

  • PRIORITY :

    Priority policy.

  • BALANCE :

    Balanced distribution policy.

"PRIORITY"

VpcId

string

No

The VPC ID associated with the launch template or existing instance rule for auto scaling.

"vpc-bp1j55oz3bg*****"

VSwitchIds

string

No

The list of vSwitch IDs in the VPC. Separate multiple IDs with commas (,).

"vsw-bp1ldxs3d4fd*****"

ScalingPolicy

string

No

The reclamation mode for scale-in. Valid values:

  • release: Release mode.

  • recycle: Stop and reclaim mode.

Valid values:

  • release :

    Release mode.

  • recycle :

    Stop and reclaim mode.

"release"

TemplateInstanceId

string

No

The instance ID for the existing instance rule of auto scaling. This parameter is valid only when OutEnable is set to true.

"1"

TemplateInstanceName

string

No

The instance name for the existing instance rule of auto scaling. This parameter is valid only when TemplateInstanceId is specified.

"tpl-tdy218"

Password

string

No

The logon password of the instance. This parameter is valid only when the existing instance rule is used for auto scaling.

"Pwd*****"

KeyPairName

string

No

The name of the logon key pair for the instance. This parameter is valid only when the existing instance rule is used for auto scaling.

"tdy218"

AcceptEULA

boolean

No

Must be set to true if auto scaling is used.

true

TemplateId

string

No

The launch template ID for auto scaling. This parameter is valid only when OutEnable is set to true, and it has a higher priority than TemplateInstanceId.

"lt-wz9hkhn8wp*****"

TemplateVersion

integer

No

The launch template version for auto scaling. This parameter is valid only when OutEnable is set to true. Set this parameter to -1 to use the default template version, or set it to a specific version number.

-1

Response elements

Element

Type

Description

Example

object

Code

integer

The status code.

200

Message

string

The message.

success

RequestId

string

The request ID.

CB36E997-FE54-476C-8C0D-********

Examples

Success response

JSON format

{
  "Code": 200,
  "Message": "success",
  "RequestId": "CB36E997-FE54-476C-8C0D-********"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.