<reponame>rhysmdnz/pulumi-alicloud-rhys-hacks// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.AliCloud.Ecs
{
    /// <summary>
    /// Provides a ECS Storage Capacity Unit resource.
    /// 
    /// For information about ECS Storage Capacity Unit and how to use it, see [What is Storage Capacity Unit](https://www.alibabacloud.com/help/en/doc-detail/161157.html).
    /// 
    /// &gt; **NOTE:** Available in v1.155.0+.
    /// 
    /// ## Example Usage
    /// 
    /// Basic Usage
    /// 
    /// ```csharp
    /// using System.Collections.Generic;
    /// using Pulumi;
    /// using AliCloud = Pulumi.AliCloud;
    /// 
    /// return await Deployment.RunAsync(() =&gt; 
    /// {
    ///     var @default = new AliCloud.Ecs.StorageCapacityUnit("default", new()
    ///     {
    ///         Capacity = 20,
    ///         Description = "tftestdescription",
    ///         StorageCapacityUnitName = "tftestname",
    ///     });
    /// 
    /// });
    /// ```
    /// 
    /// ## Import
    /// 
    /// ECS Storage Capacity Unit can be imported using the id, e.g.
    /// 
    /// ```sh
    ///  $ pulumi import alicloud:ecs/storageCapacityUnit:StorageCapacityUnit example &lt;id&gt;
    /// ```
    /// </summary>
    [AliCloudResourceType("alicloud:ecs/storageCapacityUnit:StorageCapacityUnit")]
    public partial class StorageCapacityUnit : global::Pulumi.CustomResource
    {
        /// <summary>
        /// The capacity of the Storage Capacity Unit. Unit: GiB. Valid values: `20`, `40`, `100`, `200`, `500`, `1024`, `2048`, `5120`, `10240`, `20480`, and `51200`.
        /// </summary>
        [Output("capacity")]
        public Output<int> Capacity { get; private set; } = null!;

        /// <summary>
        /// The description of the Storage Capacity Unit. The description must be 2 to 256 characters in length and cannot start with `http://` or `https://`.
        /// </summary>
        [Output("description")]
        public Output<string?> Description { get; private set; } = null!;

        /// <summary>
        /// The validity period of the Storage Capacity Unit. Default value: `1`.
        /// * When PeriodUnit is set to Month, Valid values: `1`, `2`, `3`, `6`.
        /// * When PeriodUnit is set to Year, Valid values: `1`, `3`, `5`.
        /// </summary>
        [Output("period")]
        public Output<int> Period { get; private set; } = null!;

        /// <summary>
        /// The unit of the validity period of the Storage Capacity Unit. Default value: `Month`. Valid values: `Month`, `Year`.
        /// </summary>
        [Output("periodUnit")]
        public Output<string> PeriodUnit { get; private set; } = null!;

        /// <summary>
        /// The time when the Storage Capacity Unit takes effect. It cannot be earlier than or more than six months later than the time when the Storage Capacity Unit is created. Specify the time in the ISO 8601 standard in the `yyyy-MM-ddTHH:mm:ssZ` format. The time must be in UTC. **NOTE:** This parameter is empty by default. The Storage Capacity Unit immediately takes effect after it is created.
        /// </summary>
        [Output("startTime")]
        public Output<string> StartTime { get; private set; } = null!;

        /// <summary>
        /// The status of Storage Capacity Unit.
        /// </summary>
        [Output("status")]
        public Output<string> Status { get; private set; } = null!;

        /// <summary>
        /// The name of the Storage Capacity Unit.
        /// </summary>
        [Output("storageCapacityUnitName")]
        public Output<string> StorageCapacityUnitName { get; private set; } = null!;


        /// <summary>
        /// Create a StorageCapacityUnit resource with the given unique name, arguments, and options.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resource</param>
        /// <param name="args">The arguments used to populate this resource's properties</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public StorageCapacityUnit(string name, StorageCapacityUnitArgs args, CustomResourceOptions? options = null)
            : base("alicloud:ecs/storageCapacityUnit:StorageCapacityUnit", name, args ?? new StorageCapacityUnitArgs(), MakeResourceOptions(options, ""))
        {
        }

        private StorageCapacityUnit(string name, Input<string> id, StorageCapacityUnitState? state = null, CustomResourceOptions? options = null)
            : base("alicloud:ecs/storageCapacityUnit:StorageCapacityUnit", name, state, MakeResourceOptions(options, id))
        {
        }

        private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
        {
            var defaultOptions = new CustomResourceOptions
            {
                Version = Utilities.Version,
                PluginDownloadURL = "github://api.github.com/rhysmdnz/pulumi-alicloud",
            };
            var merged = CustomResourceOptions.Merge(defaultOptions, options);
            // Override the ID if one was specified for consistency with other language SDKs.
            merged.Id = id ?? merged.Id;
            return merged;
        }
        /// <summary>
        /// Get an existing StorageCapacityUnit resource's state with the given name, ID, and optional extra
        /// properties used to qualify the lookup.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resulting resource.</param>
        /// <param name="id">The unique provider ID of the resource to lookup.</param>
        /// <param name="state">Any extra arguments used during the lookup.</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public static StorageCapacityUnit Get(string name, Input<string> id, StorageCapacityUnitState? state = null, CustomResourceOptions? options = null)
        {
            return new StorageCapacityUnit(name, id, state, options);
        }
    }

    public sealed class StorageCapacityUnitArgs : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// The capacity of the Storage Capacity Unit. Unit: GiB. Valid values: `20`, `40`, `100`, `200`, `500`, `1024`, `2048`, `5120`, `10240`, `20480`, and `51200`.
        /// </summary>
        [Input("capacity", required: true)]
        public Input<int> Capacity { get; set; } = null!;

        /// <summary>
        /// The description of the Storage Capacity Unit. The description must be 2 to 256 characters in length and cannot start with `http://` or `https://`.
        /// </summary>
        [Input("description")]
        public Input<string>? Description { get; set; }

        /// <summary>
        /// The validity period of the Storage Capacity Unit. Default value: `1`.
        /// * When PeriodUnit is set to Month, Valid values: `1`, `2`, `3`, `6`.
        /// * When PeriodUnit is set to Year, Valid values: `1`, `3`, `5`.
        /// </summary>
        [Input("period")]
        public Input<int>? Period { get; set; }

        /// <summary>
        /// The unit of the validity period of the Storage Capacity Unit. Default value: `Month`. Valid values: `Month`, `Year`.
        /// </summary>
        [Input("periodUnit")]
        public Input<string>? PeriodUnit { get; set; }

        /// <summary>
        /// The time when the Storage Capacity Unit takes effect. It cannot be earlier than or more than six months later than the time when the Storage Capacity Unit is created. Specify the time in the ISO 8601 standard in the `yyyy-MM-ddTHH:mm:ssZ` format. The time must be in UTC. **NOTE:** This parameter is empty by default. The Storage Capacity Unit immediately takes effect after it is created.
        /// </summary>
        [Input("startTime")]
        public Input<string>? StartTime { get; set; }

        /// <summary>
        /// The name of the Storage Capacity Unit.
        /// </summary>
        [Input("storageCapacityUnitName")]
        public Input<string>? StorageCapacityUnitName { get; set; }

        public StorageCapacityUnitArgs()
        {
        }
        public static new StorageCapacityUnitArgs Empty => new StorageCapacityUnitArgs();
    }

    public sealed class StorageCapacityUnitState : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// The capacity of the Storage Capacity Unit. Unit: GiB. Valid values: `20`, `40`, `100`, `200`, `500`, `1024`, `2048`, `5120`, `10240`, `20480`, and `51200`.
        /// </summary>
        [Input("capacity")]
        public Input<int>? Capacity { get; set; }

        /// <summary>
        /// The description of the Storage Capacity Unit. The description must be 2 to 256 characters in length and cannot start with `http://` or `https://`.
        /// </summary>
        [Input("description")]
        public Input<string>? Description { get; set; }

        /// <summary>
        /// The validity period of the Storage Capacity Unit. Default value: `1`.
        /// * When PeriodUnit is set to Month, Valid values: `1`, `2`, `3`, `6`.
        /// * When PeriodUnit is set to Year, Valid values: `1`, `3`, `5`.
        /// </summary>
        [Input("period")]
        public Input<int>? Period { get; set; }

        /// <summary>
        /// The unit of the validity period of the Storage Capacity Unit. Default value: `Month`. Valid values: `Month`, `Year`.
        /// </summary>
        [Input("periodUnit")]
        public Input<string>? PeriodUnit { get; set; }

        /// <summary>
        /// The time when the Storage Capacity Unit takes effect. It cannot be earlier than or more than six months later than the time when the Storage Capacity Unit is created. Specify the time in the ISO 8601 standard in the `yyyy-MM-ddTHH:mm:ssZ` format. The time must be in UTC. **NOTE:** This parameter is empty by default. The Storage Capacity Unit immediately takes effect after it is created.
        /// </summary>
        [Input("startTime")]
        public Input<string>? StartTime { get; set; }

        /// <summary>
        /// The status of Storage Capacity Unit.
        /// </summary>
        [Input("status")]
        public Input<string>? Status { get; set; }

        /// <summary>
        /// The name of the Storage Capacity Unit.
        /// </summary>
        [Input("storageCapacityUnitName")]
        public Input<string>? StorageCapacityUnitName { get; set; }

        public StorageCapacityUnitState()
        {
        }
        public static new StorageCapacityUnitState Empty => new StorageCapacityUnitState();
    }
}
