1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. ecs
  5. ElasticityAssurance
Alibaba Cloud v3.87.0 published on Saturday, Oct 18, 2025 by Pulumi

alicloud.ecs.ElasticityAssurance

Deploy with Pulumi
alicloud logo
Alibaba Cloud v3.87.0 published on Saturday, Oct 18, 2025 by Pulumi

    Provides a ECS Elasticity Assurance resource.

    For information about ECS Elasticity Assurance and how to use it, see What is Elasticity Assurance.

    NOTE: Available since v1.196.0.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const config = new pulumi.Config();
    const name = config.get("name") || "terraform-example";
    const _default = alicloud.resourcemanager.getResourceGroups({
        status: "OK",
    });
    const defaultGetInstanceTypes = alicloud.ecs.getInstanceTypes({
        instanceTypeFamily: "ecs.c6",
    });
    const defaultElasticityAssurance = new alicloud.ecs.ElasticityAssurance("default", {
        instanceAmount: 1,
        description: "before",
        zoneIds: [defaultGetInstanceTypes.then(defaultGetInstanceTypes => defaultGetInstanceTypes.instanceTypes?.[0]?.availabilityZones?.[0])],
        privatePoolOptionsName: name,
        period: 1,
        privatePoolOptionsMatchCriteria: "Open",
        instanceType: defaultGetInstanceTypes.then(defaultGetInstanceTypes => defaultGetInstanceTypes.instanceTypes?.[0]?.id),
        periodUnit: "Month",
        assuranceTimes: "Unlimited",
        resourceGroupId: _default.then(_default => _default.ids?.[0]),
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "terraform-example"
    default = alicloud.resourcemanager.get_resource_groups(status="OK")
    default_get_instance_types = alicloud.ecs.get_instance_types(instance_type_family="ecs.c6")
    default_elasticity_assurance = alicloud.ecs.ElasticityAssurance("default",
        instance_amount=1,
        description="before",
        zone_ids=[default_get_instance_types.instance_types[0].availability_zones[0]],
        private_pool_options_name=name,
        period=1,
        private_pool_options_match_criteria="Open",
        instance_type=default_get_instance_types.instance_types[0].id,
        period_unit="Month",
        assurance_times="Unlimited",
        resource_group_id=default.ids[0])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/resourcemanager"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		name := "terraform-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		_default, err := resourcemanager.GetResourceGroups(ctx, &resourcemanager.GetResourceGroupsArgs{
    			Status: pulumi.StringRef("OK"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultGetInstanceTypes, err := ecs.GetInstanceTypes(ctx, &ecs.GetInstanceTypesArgs{
    			InstanceTypeFamily: pulumi.StringRef("ecs.c6"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		_, err = ecs.NewElasticityAssurance(ctx, "default", &ecs.ElasticityAssuranceArgs{
    			InstanceAmount: pulumi.Int(1),
    			Description:    pulumi.String("before"),
    			ZoneIds: pulumi.StringArray{
    				pulumi.String(defaultGetInstanceTypes.InstanceTypes[0].AvailabilityZones[0]),
    			},
    			PrivatePoolOptionsName:          pulumi.String(name),
    			Period:                          pulumi.Int(1),
    			PrivatePoolOptionsMatchCriteria: pulumi.String("Open"),
    			InstanceType:                    pulumi.String(defaultGetInstanceTypes.InstanceTypes[0].Id),
    			PeriodUnit:                      pulumi.String("Month"),
    			AssuranceTimes:                  pulumi.String("Unlimited"),
    			ResourceGroupId:                 pulumi.String(_default.Ids[0]),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.Get("name") ?? "terraform-example";
        var @default = AliCloud.ResourceManager.GetResourceGroups.Invoke(new()
        {
            Status = "OK",
        });
    
        var defaultGetInstanceTypes = AliCloud.Ecs.GetInstanceTypes.Invoke(new()
        {
            InstanceTypeFamily = "ecs.c6",
        });
    
        var defaultElasticityAssurance = new AliCloud.Ecs.ElasticityAssurance("default", new()
        {
            InstanceAmount = 1,
            Description = "before",
            ZoneIds = new[]
            {
                defaultGetInstanceTypes.Apply(getInstanceTypesResult => getInstanceTypesResult.InstanceTypes[0]?.AvailabilityZones[0]),
            },
            PrivatePoolOptionsName = name,
            Period = 1,
            PrivatePoolOptionsMatchCriteria = "Open",
            InstanceType = defaultGetInstanceTypes.Apply(getInstanceTypesResult => getInstanceTypesResult.InstanceTypes[0]?.Id),
            PeriodUnit = "Month",
            AssuranceTimes = "Unlimited",
            ResourceGroupId = @default.Apply(@default => @default.Apply(getResourceGroupsResult => getResourceGroupsResult.Ids[0])),
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
    import com.pulumi.alicloud.resourcemanager.inputs.GetResourceGroupsArgs;
    import com.pulumi.alicloud.ecs.EcsFunctions;
    import com.pulumi.alicloud.ecs.inputs.GetInstanceTypesArgs;
    import com.pulumi.alicloud.ecs.ElasticityAssurance;
    import com.pulumi.alicloud.ecs.ElasticityAssuranceArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var config = ctx.config();
            final var name = config.get("name").orElse("terraform-example");
            final var default = ResourcemanagerFunctions.getResourceGroups(GetResourceGroupsArgs.builder()
                .status("OK")
                .build());
    
            final var defaultGetInstanceTypes = EcsFunctions.getInstanceTypes(GetInstanceTypesArgs.builder()
                .instanceTypeFamily("ecs.c6")
                .build());
    
            var defaultElasticityAssurance = new ElasticityAssurance("defaultElasticityAssurance", ElasticityAssuranceArgs.builder()
                .instanceAmount(1)
                .description("before")
                .zoneIds(defaultGetInstanceTypes.instanceTypes()[0].availabilityZones()[0])
                .privatePoolOptionsName(name)
                .period(1)
                .privatePoolOptionsMatchCriteria("Open")
                .instanceType(defaultGetInstanceTypes.instanceTypes()[0].id())
                .periodUnit("Month")
                .assuranceTimes("Unlimited")
                .resourceGroupId(default_.ids()[0])
                .build());
    
        }
    }
    
    configuration:
      name:
        type: string
        default: terraform-example
    resources:
      defaultElasticityAssurance:
        type: alicloud:ecs:ElasticityAssurance
        name: default
        properties:
          instanceAmount: 1
          description: before
          zoneIds:
            - ${defaultGetInstanceTypes.instanceTypes[0].availabilityZones[0]}
          privatePoolOptionsName: ${name}
          period: 1
          privatePoolOptionsMatchCriteria: Open
          instanceType: ${defaultGetInstanceTypes.instanceTypes[0].id}
          periodUnit: Month
          assuranceTimes: Unlimited
          resourceGroupId: ${default.ids[0]}
    variables:
      default:
        fn::invoke:
          function: alicloud:resourcemanager:getResourceGroups
          arguments:
            status: OK
      defaultGetInstanceTypes:
        fn::invoke:
          function: alicloud:ecs:getInstanceTypes
          arguments:
            instanceTypeFamily: ecs.c6
    

    Create ElasticityAssurance Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ElasticityAssurance(name: string, args: ElasticityAssuranceArgs, opts?: CustomResourceOptions);
    @overload
    def ElasticityAssurance(resource_name: str,
                            args: ElasticityAssuranceArgs,
                            opts: Optional[ResourceOptions] = None)
    
    @overload
    def ElasticityAssurance(resource_name: str,
                            opts: Optional[ResourceOptions] = None,
                            instance_amount: Optional[int] = None,
                            zone_ids: Optional[Sequence[str]] = None,
                            instance_type: Optional[str] = None,
                            auto_renew_period_unit: Optional[str] = None,
                            description: Optional[str] = None,
                            assurance_times: Optional[str] = None,
                            auto_renew_period: Optional[int] = None,
                            period: Optional[int] = None,
                            period_unit: Optional[str] = None,
                            private_pool_options_match_criteria: Optional[str] = None,
                            private_pool_options_name: Optional[str] = None,
                            resource_group_id: Optional[str] = None,
                            start_time: Optional[str] = None,
                            tags: Optional[Mapping[str, str]] = None,
                            auto_renew: Optional[bool] = None)
    func NewElasticityAssurance(ctx *Context, name string, args ElasticityAssuranceArgs, opts ...ResourceOption) (*ElasticityAssurance, error)
    public ElasticityAssurance(string name, ElasticityAssuranceArgs args, CustomResourceOptions? opts = null)
    public ElasticityAssurance(String name, ElasticityAssuranceArgs args)
    public ElasticityAssurance(String name, ElasticityAssuranceArgs args, CustomResourceOptions options)
    
    type: alicloud:ecs:ElasticityAssurance
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args ElasticityAssuranceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args ElasticityAssuranceArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args ElasticityAssuranceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ElasticityAssuranceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ElasticityAssuranceArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var elasticityAssuranceResource = new AliCloud.Ecs.ElasticityAssurance("elasticityAssuranceResource", new()
    {
        InstanceAmount = 0,
        ZoneIds = new[]
        {
            "string",
        },
        InstanceType = "string",
        AutoRenewPeriodUnit = "string",
        Description = "string",
        AssuranceTimes = "string",
        AutoRenewPeriod = 0,
        Period = 0,
        PeriodUnit = "string",
        PrivatePoolOptionsMatchCriteria = "string",
        PrivatePoolOptionsName = "string",
        ResourceGroupId = "string",
        StartTime = "string",
        Tags = 
        {
            { "string", "string" },
        },
        AutoRenew = false,
    });
    
    example, err := ecs.NewElasticityAssurance(ctx, "elasticityAssuranceResource", &ecs.ElasticityAssuranceArgs{
    	InstanceAmount: pulumi.Int(0),
    	ZoneIds: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	InstanceType:                    pulumi.String("string"),
    	AutoRenewPeriodUnit:             pulumi.String("string"),
    	Description:                     pulumi.String("string"),
    	AssuranceTimes:                  pulumi.String("string"),
    	AutoRenewPeriod:                 pulumi.Int(0),
    	Period:                          pulumi.Int(0),
    	PeriodUnit:                      pulumi.String("string"),
    	PrivatePoolOptionsMatchCriteria: pulumi.String("string"),
    	PrivatePoolOptionsName:          pulumi.String("string"),
    	ResourceGroupId:                 pulumi.String("string"),
    	StartTime:                       pulumi.String("string"),
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	AutoRenew: pulumi.Bool(false),
    })
    
    var elasticityAssuranceResource = new ElasticityAssurance("elasticityAssuranceResource", ElasticityAssuranceArgs.builder()
        .instanceAmount(0)
        .zoneIds("string")
        .instanceType("string")
        .autoRenewPeriodUnit("string")
        .description("string")
        .assuranceTimes("string")
        .autoRenewPeriod(0)
        .period(0)
        .periodUnit("string")
        .privatePoolOptionsMatchCriteria("string")
        .privatePoolOptionsName("string")
        .resourceGroupId("string")
        .startTime("string")
        .tags(Map.of("string", "string"))
        .autoRenew(false)
        .build());
    
    elasticity_assurance_resource = alicloud.ecs.ElasticityAssurance("elasticityAssuranceResource",
        instance_amount=0,
        zone_ids=["string"],
        instance_type="string",
        auto_renew_period_unit="string",
        description="string",
        assurance_times="string",
        auto_renew_period=0,
        period=0,
        period_unit="string",
        private_pool_options_match_criteria="string",
        private_pool_options_name="string",
        resource_group_id="string",
        start_time="string",
        tags={
            "string": "string",
        },
        auto_renew=False)
    
    const elasticityAssuranceResource = new alicloud.ecs.ElasticityAssurance("elasticityAssuranceResource", {
        instanceAmount: 0,
        zoneIds: ["string"],
        instanceType: "string",
        autoRenewPeriodUnit: "string",
        description: "string",
        assuranceTimes: "string",
        autoRenewPeriod: 0,
        period: 0,
        periodUnit: "string",
        privatePoolOptionsMatchCriteria: "string",
        privatePoolOptionsName: "string",
        resourceGroupId: "string",
        startTime: "string",
        tags: {
            string: "string",
        },
        autoRenew: false,
    });
    
    type: alicloud:ecs:ElasticityAssurance
    properties:
        assuranceTimes: string
        autoRenew: false
        autoRenewPeriod: 0
        autoRenewPeriodUnit: string
        description: string
        instanceAmount: 0
        instanceType: string
        period: 0
        periodUnit: string
        privatePoolOptionsMatchCriteria: string
        privatePoolOptionsName: string
        resourceGroupId: string
        startTime: string
        tags:
            string: string
        zoneIds:
            - string
    

    ElasticityAssurance Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The ElasticityAssurance resource accepts the following input properties:

    InstanceAmount int
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    InstanceType string
    Instance type. Currently, only one instance type is supported.
    ZoneIds List<string>
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    AssuranceTimes string
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    AutoRenew bool

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    AutoRenewPeriod int

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    AutoRenewPeriodUnit string

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    Description string
    Description of flexible guarantee service.
    Period int
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    PeriodUnit string
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    PrivatePoolOptionsMatchCriteria string
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    PrivatePoolOptionsName string
    The name of the flexible protection service.
    ResourceGroupId string
    The ID of the resource group.
    StartTime string
    Flexible guarantee service effective time.
    Tags Dictionary<string, string>
    The tag key-value pair information bound by the elastic guarantee service.
    InstanceAmount int
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    InstanceType string
    Instance type. Currently, only one instance type is supported.
    ZoneIds []string
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    AssuranceTimes string
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    AutoRenew bool

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    AutoRenewPeriod int

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    AutoRenewPeriodUnit string

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    Description string
    Description of flexible guarantee service.
    Period int
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    PeriodUnit string
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    PrivatePoolOptionsMatchCriteria string
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    PrivatePoolOptionsName string
    The name of the flexible protection service.
    ResourceGroupId string
    The ID of the resource group.
    StartTime string
    Flexible guarantee service effective time.
    Tags map[string]string
    The tag key-value pair information bound by the elastic guarantee service.
    instanceAmount Integer
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instanceType String
    Instance type. Currently, only one instance type is supported.
    zoneIds List<String>
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assuranceTimes String
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    autoRenew Boolean

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    autoRenewPeriod Integer

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    autoRenewPeriodUnit String

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description String
    Description of flexible guarantee service.
    period Integer
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    periodUnit String
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    privatePoolOptionsMatchCriteria String
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    privatePoolOptionsName String
    The name of the flexible protection service.
    resourceGroupId String
    The ID of the resource group.
    startTime String
    Flexible guarantee service effective time.
    tags Map<String,String>
    The tag key-value pair information bound by the elastic guarantee service.
    instanceAmount number
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instanceType string
    Instance type. Currently, only one instance type is supported.
    zoneIds string[]
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assuranceTimes string
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    autoRenew boolean

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    autoRenewPeriod number

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    autoRenewPeriodUnit string

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description string
    Description of flexible guarantee service.
    period number
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    periodUnit string
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    privatePoolOptionsMatchCriteria string
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    privatePoolOptionsName string
    The name of the flexible protection service.
    resourceGroupId string
    The ID of the resource group.
    startTime string
    Flexible guarantee service effective time.
    tags {[key: string]: string}
    The tag key-value pair information bound by the elastic guarantee service.
    instance_amount int
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instance_type str
    Instance type. Currently, only one instance type is supported.
    zone_ids Sequence[str]
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assurance_times str
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    auto_renew bool

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    auto_renew_period int

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    auto_renew_period_unit str

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description str
    Description of flexible guarantee service.
    period int
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    period_unit str
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    private_pool_options_match_criteria str
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    private_pool_options_name str
    The name of the flexible protection service.
    resource_group_id str
    The ID of the resource group.
    start_time str
    Flexible guarantee service effective time.
    tags Mapping[str, str]
    The tag key-value pair information bound by the elastic guarantee service.
    instanceAmount Number
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instanceType String
    Instance type. Currently, only one instance type is supported.
    zoneIds List<String>
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assuranceTimes String
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    autoRenew Boolean

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    autoRenewPeriod Number

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    autoRenewPeriodUnit String

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description String
    Description of flexible guarantee service.
    period Number
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    periodUnit String
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    privatePoolOptionsMatchCriteria String
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    privatePoolOptionsName String
    The name of the flexible protection service.
    resourceGroupId String
    The ID of the resource group.
    startTime String
    Flexible guarantee service effective time.
    tags Map<String>
    The tag key-value pair information bound by the elastic guarantee service.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ElasticityAssurance resource produces the following output properties:

    ElasticityAssuranceId string
    The first ID of the resource
    EndTime string
    Flexible guarantee service failure time.
    Id string
    The provider-assigned unique ID for this managed resource.
    InstanceChargeType string
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    RegionId string
    (Available since v1.261.0) The region ID of the elasticity assurance.
    StartTimeType string
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    Status string
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    UsedAssuranceTimes int
    This parameter is not yet available.
    ElasticityAssuranceId string
    The first ID of the resource
    EndTime string
    Flexible guarantee service failure time.
    Id string
    The provider-assigned unique ID for this managed resource.
    InstanceChargeType string
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    RegionId string
    (Available since v1.261.0) The region ID of the elasticity assurance.
    StartTimeType string
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    Status string
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    UsedAssuranceTimes int
    This parameter is not yet available.
    elasticityAssuranceId String
    The first ID of the resource
    endTime String
    Flexible guarantee service failure time.
    id String
    The provider-assigned unique ID for this managed resource.
    instanceChargeType String
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    regionId String
    (Available since v1.261.0) The region ID of the elasticity assurance.
    startTimeType String
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status String
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    usedAssuranceTimes Integer
    This parameter is not yet available.
    elasticityAssuranceId string
    The first ID of the resource
    endTime string
    Flexible guarantee service failure time.
    id string
    The provider-assigned unique ID for this managed resource.
    instanceChargeType string
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    regionId string
    (Available since v1.261.0) The region ID of the elasticity assurance.
    startTimeType string
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status string
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    usedAssuranceTimes number
    This parameter is not yet available.
    elasticity_assurance_id str
    The first ID of the resource
    end_time str
    Flexible guarantee service failure time.
    id str
    The provider-assigned unique ID for this managed resource.
    instance_charge_type str
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    region_id str
    (Available since v1.261.0) The region ID of the elasticity assurance.
    start_time_type str
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status str
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    used_assurance_times int
    This parameter is not yet available.
    elasticityAssuranceId String
    The first ID of the resource
    endTime String
    Flexible guarantee service failure time.
    id String
    The provider-assigned unique ID for this managed resource.
    instanceChargeType String
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    regionId String
    (Available since v1.261.0) The region ID of the elasticity assurance.
    startTimeType String
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status String
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    usedAssuranceTimes Number
    This parameter is not yet available.

    Look up Existing ElasticityAssurance Resource

    Get an existing ElasticityAssurance resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: ElasticityAssuranceState, opts?: CustomResourceOptions): ElasticityAssurance
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            assurance_times: Optional[str] = None,
            auto_renew: Optional[bool] = None,
            auto_renew_period: Optional[int] = None,
            auto_renew_period_unit: Optional[str] = None,
            description: Optional[str] = None,
            elasticity_assurance_id: Optional[str] = None,
            end_time: Optional[str] = None,
            instance_amount: Optional[int] = None,
            instance_charge_type: Optional[str] = None,
            instance_type: Optional[str] = None,
            period: Optional[int] = None,
            period_unit: Optional[str] = None,
            private_pool_options_match_criteria: Optional[str] = None,
            private_pool_options_name: Optional[str] = None,
            region_id: Optional[str] = None,
            resource_group_id: Optional[str] = None,
            start_time: Optional[str] = None,
            start_time_type: Optional[str] = None,
            status: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None,
            used_assurance_times: Optional[int] = None,
            zone_ids: Optional[Sequence[str]] = None) -> ElasticityAssurance
    func GetElasticityAssurance(ctx *Context, name string, id IDInput, state *ElasticityAssuranceState, opts ...ResourceOption) (*ElasticityAssurance, error)
    public static ElasticityAssurance Get(string name, Input<string> id, ElasticityAssuranceState? state, CustomResourceOptions? opts = null)
    public static ElasticityAssurance get(String name, Output<String> id, ElasticityAssuranceState state, CustomResourceOptions options)
    resources:  _:    type: alicloud:ecs:ElasticityAssurance    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AssuranceTimes string
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    AutoRenew bool

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    AutoRenewPeriod int

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    AutoRenewPeriodUnit string

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    Description string
    Description of flexible guarantee service.
    ElasticityAssuranceId string
    The first ID of the resource
    EndTime string
    Flexible guarantee service failure time.
    InstanceAmount int
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    InstanceChargeType string
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    InstanceType string
    Instance type. Currently, only one instance type is supported.
    Period int
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    PeriodUnit string
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    PrivatePoolOptionsMatchCriteria string
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    PrivatePoolOptionsName string
    The name of the flexible protection service.
    RegionId string
    (Available since v1.261.0) The region ID of the elasticity assurance.
    ResourceGroupId string
    The ID of the resource group.
    StartTime string
    Flexible guarantee service effective time.
    StartTimeType string
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    Status string
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    Tags Dictionary<string, string>
    The tag key-value pair information bound by the elastic guarantee service.
    UsedAssuranceTimes int
    This parameter is not yet available.
    ZoneIds List<string>
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    AssuranceTimes string
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    AutoRenew bool

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    AutoRenewPeriod int

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    AutoRenewPeriodUnit string

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    Description string
    Description of flexible guarantee service.
    ElasticityAssuranceId string
    The first ID of the resource
    EndTime string
    Flexible guarantee service failure time.
    InstanceAmount int
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    InstanceChargeType string
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    InstanceType string
    Instance type. Currently, only one instance type is supported.
    Period int
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    PeriodUnit string
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    PrivatePoolOptionsMatchCriteria string
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    PrivatePoolOptionsName string
    The name of the flexible protection service.
    RegionId string
    (Available since v1.261.0) The region ID of the elasticity assurance.
    ResourceGroupId string
    The ID of the resource group.
    StartTime string
    Flexible guarantee service effective time.
    StartTimeType string
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    Status string
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    Tags map[string]string
    The tag key-value pair information bound by the elastic guarantee service.
    UsedAssuranceTimes int
    This parameter is not yet available.
    ZoneIds []string
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assuranceTimes String
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    autoRenew Boolean

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    autoRenewPeriod Integer

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    autoRenewPeriodUnit String

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description String
    Description of flexible guarantee service.
    elasticityAssuranceId String
    The first ID of the resource
    endTime String
    Flexible guarantee service failure time.
    instanceAmount Integer
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instanceChargeType String
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    instanceType String
    Instance type. Currently, only one instance type is supported.
    period Integer
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    periodUnit String
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    privatePoolOptionsMatchCriteria String
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    privatePoolOptionsName String
    The name of the flexible protection service.
    regionId String
    (Available since v1.261.0) The region ID of the elasticity assurance.
    resourceGroupId String
    The ID of the resource group.
    startTime String
    Flexible guarantee service effective time.
    startTimeType String
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status String
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    tags Map<String,String>
    The tag key-value pair information bound by the elastic guarantee service.
    usedAssuranceTimes Integer
    This parameter is not yet available.
    zoneIds List<String>
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assuranceTimes string
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    autoRenew boolean

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    autoRenewPeriod number

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    autoRenewPeriodUnit string

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description string
    Description of flexible guarantee service.
    elasticityAssuranceId string
    The first ID of the resource
    endTime string
    Flexible guarantee service failure time.
    instanceAmount number
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instanceChargeType string
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    instanceType string
    Instance type. Currently, only one instance type is supported.
    period number
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    periodUnit string
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    privatePoolOptionsMatchCriteria string
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    privatePoolOptionsName string
    The name of the flexible protection service.
    regionId string
    (Available since v1.261.0) The region ID of the elasticity assurance.
    resourceGroupId string
    The ID of the resource group.
    startTime string
    Flexible guarantee service effective time.
    startTimeType string
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status string
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    tags {[key: string]: string}
    The tag key-value pair information bound by the elastic guarantee service.
    usedAssuranceTimes number
    This parameter is not yet available.
    zoneIds string[]
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assurance_times str
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    auto_renew bool

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    auto_renew_period int

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    auto_renew_period_unit str

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description str
    Description of flexible guarantee service.
    elasticity_assurance_id str
    The first ID of the resource
    end_time str
    Flexible guarantee service failure time.
    instance_amount int
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instance_charge_type str
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    instance_type str
    Instance type. Currently, only one instance type is supported.
    period int
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    period_unit str
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    private_pool_options_match_criteria str
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    private_pool_options_name str
    The name of the flexible protection service.
    region_id str
    (Available since v1.261.0) The region ID of the elasticity assurance.
    resource_group_id str
    The ID of the resource group.
    start_time str
    Flexible guarantee service effective time.
    start_time_type str
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status str
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    tags Mapping[str, str]
    The tag key-value pair information bound by the elastic guarantee service.
    used_assurance_times int
    This parameter is not yet available.
    zone_ids Sequence[str]
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.
    assuranceTimes String
    The total number of times that the elasticity assurance can be applied. Set the value to Unlimited. This value indicates that the elasticity assurance can be applied an unlimited number of times within its effective duration. Default value: Unlimited.
    autoRenew Boolean

    Specifies whether to enable auto-renewal for the elasticity assurance. Valid values:

    • true
    • false

    Default value: false.

    autoRenewPeriod Number

    The auto-renewal period. Unit: month. Valid values: 1, 2, 3, 6, 12, 24, and 36.

    • Default value when PeriodUnit is set to Month: 1.
    • Default value when PeriodUnit is set to Year: 12.

    NOTE: If you set AutoRenew to true, you must specify this parameter.

    autoRenewPeriodUnit String

    Unit of duration. Value range:

    • Month: Month
    • Year: Year

    Default value: Year

    description String
    Description of flexible guarantee service.
    elasticityAssuranceId String
    The first ID of the resource
    endTime String
    Flexible guarantee service failure time.
    instanceAmount Number
    The total number of instances for which to reserve the capacity of an instance type. Valid values: 1 to 1000. NOTE: From version 1.261.0, instance_amount can be modified.
    instanceChargeType String
    The billing method of the instance. Possible value: PostPaid. Currently, only pay-as-you-go is supported.
    instanceType String
    Instance type. Currently, only one instance type is supported.
    period Number
    Length of purchase. The unit of duration is determined by the 'period_unit' parameter. Default value: 1.

    • When the period_unit parameter is set to Month, the valid values are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
    • When the period_unit parameter is set to Year, the valid values are 1, 2, 3, 4, and 5.
    periodUnit String
    Duration unit. Value range:-Month: Month-Year: YearDefault value: Year
    privatePoolOptionsMatchCriteria String
    The matching mode of flexible guarantee service. Possible values:-Open: flexible guarantee service for Open mode.-Target: specifies the flexible guarantee service of the mode.
    privatePoolOptionsName String
    The name of the flexible protection service.
    regionId String
    (Available since v1.261.0) The region ID of the elasticity assurance.
    resourceGroupId String
    The ID of the resource group.
    startTime String
    Flexible guarantee service effective time.
    startTimeType String
    Flexible guarantee effective way. Possible values:-Now: Effective immediately.-Later: the specified time takes effect.
    status String
    The status of flexible guarantee services. Possible values:-Preparing: in preparation.-Prepared: to take effect.-Active: in effect.-Released: Released.
    tags Map<String>
    The tag key-value pair information bound by the elastic guarantee service.
    usedAssuranceTimes Number
    This parameter is not yet available.
    zoneIds List<String>
    The zone ID of the region to which the elastic Protection Service belongs. Currently, only the creation of flexible protection services in one available area is supported.

    Import

    ECS Elasticity Assurance can be imported using the id, e.g.

    $ pulumi import alicloud:ecs/elasticityAssurance:ElasticityAssurance example <id>
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.87.0 published on Saturday, Oct 18, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate