All Products
Search
Document Center

Auto Scaling:DescribePatternTypes

Last Updated:Nov 11, 2024

Queries instance types. When you call the DescribePatternTypes operation, you can specify attributes such as the vSwitch ID, number of vCPUs, memory size, instance family, and maximum acceptable price to filer instance types that meet your business requirements.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
ess:DescribePatternTypeslist
  • All Resources
    *
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The region ID.

cn-hangzhou
VSwitchIdarrayNo

The IDs of the vSwitches.

stringNo

The ID of the vSwitch.

vsw-bp14zolna43z266bq****
SpotStrategystringNo

The preemption policy that you want to apply to pay-as-you-go instances. Valid values:

  • NoSpot: The instances are created as regular pay-as-you-go instances.
  • SpotWithPriceLimit: The instances are created as preemptible instances that have a user-defined maximum hourly price.
  • SpotAsPriceGo: The instances are created as preemptible instances for which the market price at the time of purchase is automatically used as the bidding price.

Default value: NoSpot.

NoSpot
CoresintegerNo

The number of vCPUs that you want to assign to the instance type.

2
MemoryfloatNo

The memory size that you want to assign to the instance type. Unit: GiB.

4
MaxPricefloatNo

The maximum hourly price for pay-as-you-go or preemptible instances.

2
InstanceFamilyLevelstringNo

The level of the instance family. Valid values:

  • EntryLevel: entry level
  • EnterpriseLevel: enterprise level
  • CreditEntryLevel: credit-based entry level For more information, see Burstable instance families.
EnterpriseLevel
ExcludedInstanceTypearrayNo

The instance types that you want to exclude. You can use wildcard characters, such as an asterisk (*), to exclude an instance type or an instance family. Examples:

  • ecs.c6.large: excludes the ecs.c6.large instance type.
  • ecs.c6.*: excludes the c6 instance family.
Note If you want to exclude multiple instance types, separate the instance types with forward slashes (/). Example: ecs.n1.small/ecs.n1.*/*7*.
stringNo

The instance type that you want to exclude. You can use wildcard characters, such as an asterisk (*), to exclude an instance type or an instance family. Examples:

  • ecs.c6.large: excludes the ecs.c6.large instance type.
  • ecs.c6.*: excludes the c6 instance family.
Note If you want to exclude multiple instance types, separate the instance types with delimiters (/). Example: ecs.n1.small/ecs.n1.*/*7*.
ecs.c6.xlarge
ArchitecturearrayNo

The architectures of instance types. Valid values:

  • X86: x86
  • Heterogeneous: heterogeneous computing, such as GPU-accelerated or FPGA-accelerated
  • BareMetal: ECS Bare Metal Instance
  • Arm: Arm
  • SuperComputeCluster: Super Computing Cluster

By default, all values are selected.

stringNo

The architecture of the instance type. Valid values:

  • X86: x86
  • Heterogeneous: heterogeneous computing, such as GPU-accelerated or FPGA-accelerated
  • BareMetal: ECS Bare Metal Instance
  • Arm: Arm
  • SuperComputeCluster: Super Computing Cluster

By default, all values are included.

X86
BurstablePerformancestringNo

Specifies whether to include burstable instance types. Valid values:

  • Exclude: does not include burstable instance types.
  • Include: includes burstable instance types.
  • Required: includes only burstable instance types.

Default value: Include.

Include
CoresListarrayNo

The number of vCPUs that you want to assign to the instance type. You can specify multiple vCPUs.

integerNo

The number of vCPUs that you want to assign to the instance type. You can specify multiple vCPUs.

2
MemoryListarrayNo

The memory size that you want to assign to the instance type. Unit: GiB. You can specify multiple memory sizes.

floatNo

The memory size that you want to assign to the instance type. Unit: GiB. You can specify multiple memory sizes.

4
ChannelIdlongNo

The channel ID. This parameter is not for public use.

79425074
InstanceTypeFamiliesarrayNo

The instance families that you want to query. You can query 1 to 10 instance families in each call.

stringNo

The instance family that you want to query. You can query 1 to 10 instance families in each call.

["ecs.g6", "ecs.c6", … "ecs.r6"]
MinimumCpuCoreCountintegerNo

The minimum number of vCPUs per instance type.

2
MaximumCpuCoreCountintegerNo

The maximum number of vCPUs per instance type.

4
GpuSpecsarrayNo

The GPU models.

stringNo

The GPU model.

["NVIDIA V100"]
InstanceCategoriesarrayNo

The categories of the instance types. Valid values:

  • General-purpose
  • Compute-optimized
  • Memory-optimized
  • Big data
  • Local SSDs
  • High Clock Speed
  • Enhanced
  • Shared
  • Compute-optimized with GPU
  • Visual Compute-optimized
  • Heterogeneous Service
  • Compute-optimized with FPGA
  • Compute-optimized with NPU
  • ECS Bare Metal
  • Super Computing Cluster
  • High Performance Compute
stringNo

The category of the instance type. Valid values:

  • General-purpose
  • Compute-optimized
  • Memory-optimized
  • Big data
  • Local SSDs
  • High Clock Speed
  • Enhanced
  • Shared
  • Compute-optimized with GPU
  • Visual Compute-optimized
  • Heterogeneous Service
  • Compute-optimized with FPGA
  • Compute-optimized with NPU
  • ECS Bare Metal
  • Super Computing Cluster
  • High Performance Compute
["Compute-optimized with GPU"]
CpuArchitecturesarrayNo

The CPU architectures of the instance types. Valid values:

Note You can specify 1 to 2 CPU architectures.
  • x86
  • Arm
stringNo

The CPU architecture of the instance type. Valid values:

Note You can specify 1 to 2 CPU architectures.
  • x86
  • Arm
["X86", "ARM"]
PhysicalProcessorModelsarrayNo

The processor models of the instance types. You can specify 1 to 10 processor models.

stringNo

The processor model of the instance type. You can specify 1 to 10 processor models.

["Intel Xeon(Ice Lake) Platinum 8369B", "Intel Xeon(Skylake) Platinum 8163", … "Intel Xeon(Cascade Lake) Platinum 8269CY"]
MinimumEniQuantityintegerNo

The minimum number of elastic network interfaces (ENIs) per instance.

2
MinimumEniPrivateIpAddressQuantityintegerNo

The minimum number of IPv4 addresses per ENI.

2
MinimumEniIpv6AddressQuantityintegerNo

The minimum number of IPv6 addresses per ENI.

1
MinimumInitialCreditintegerNo

The initial vCPU credits per t5 or t6 burstable instance.

12
MinimumBaselineCreditintegerNo

The baseline vCPU computing performance (overall baseline performance of all vCPUs) per t5 or t6 burstable instance.

12
MinimumMemorySizefloatNo

The minimum memory size per instance. Unit: GiB.

4
MaximumMemorySizefloatNo

The maximum memory size per instance. Unit: GiB.

4
MinimumGpuAmountintegerNo

The minimum number of GPUs per instance. The value must be a positive integer.

2
MaximumGpuAmountintegerNo

The maximum number of GPUs per instance. The value must be a positive integer.

2

Response parameters

ParameterTypeDescriptionExample
object

Schema of Response

RequestIdstring

The request ID.

473469C7-AA6F-4DC5-B3DB-A3DC0DE3****
PatternTypesarray<object>

The instance types that meet the specified requirements.

PatternTypeobject
InstanceTypestring

The name of the instance type.

ecs.c7.xlarge
InstanceFamilyLevelstring

The level of the instance family.

  • EntryLevel: entry level (shared instance types) Instance types of this level are the most cost-effective but may not provide stable computing performance. Instance types of this level are suitable for business scenarios in which the CPU utilization is low. For more information, see Shared instance families.
  • EnterpriseLevel: enterprise level. Instance types of this level provide stable performance and dedicated resources and are suitable for scenarios that require high stability. For more information, see Overview of instance families.
  • CreditEntryLevel: credit-based entry level (burstable instance types). CPU credits are used to ensure computing performance. Instance types of this level are suitable for scenarios in which the CPU utilization is low but may fluctuate in specific cases. For more information, see Overview of burstable instances.
EnterpriseLevel
InstanceTypeFamilystring

The instance family.

ecs.c7
Coresinteger

The number of vCPUs that are assigned to the instance type.

4
Memoryfloat

The memory size that are assigned to the instance type. Unit: GiB.

8

Examples

Sample success responses

JSONformat

{
  "RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3****",
  "PatternTypes": [
    {
      "InstanceType": "ecs.c7.xlarge",
      "InstanceFamilyLevel": "EnterpriseLevel",
      "InstanceTypeFamily": "ecs.c7",
      "Cores": 4,
      "Memory": 8
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-06-12The request parameters of the API has changedView Change Details