<filename>sdk/dotnet/Pvtz/Endpoint.cs// *** 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.Pvtz
{
    /// <summary>
    /// Provides a Private Zone Endpoint resource.
    /// 
    /// For information about Private Zone Endpoint and how to use it, see [What is Endpoint](https://www.alibabacloud.com/help/en/doc-detail/64611.htm).
    /// 
    /// &gt; **NOTE:** Available in v1.143.0+.
    /// 
    /// ## Import
    /// 
    /// Private Zone Endpoint can be imported using the id, e.g.
    /// 
    /// ```sh
    ///  $ pulumi import alicloud:pvtz/endpoint:Endpoint example &lt;id&gt;
    /// ```
    /// </summary>
    [AliCloudResourceType("alicloud:pvtz/endpoint:Endpoint")]
    public partial class Endpoint : global::Pulumi.CustomResource
    {
        /// <summary>
        /// The name of the resource.
        /// </summary>
        [Output("endpointName")]
        public Output<string> EndpointName { get; private set; } = null!;

        /// <summary>
        /// The Ip Configs. See the following `Block ip_configs`. **NOTE:** In order to ensure high availability, add at least 2 and up to 6.
        /// </summary>
        [Output("ipConfigs")]
        public Output<ImmutableArray<Outputs.EndpointIpConfig>> IpConfigs { get; private set; } = null!;

        /// <summary>
        /// The ID of the Security Group.
        /// </summary>
        [Output("securityGroupId")]
        public Output<string> SecurityGroupId { get; private set; } = null!;

        /// <summary>
        /// The status of the resource. Valid values: `CHANGE_FAILED`, `CHANGE_INIT`, `EXCEPTION`, `FAILED`, `INIT`, `SUCCESS`.
        /// </summary>
        [Output("status")]
        public Output<string> Status { get; private set; } = null!;

        /// <summary>
        /// The VPC ID.
        /// </summary>
        [Output("vpcId")]
        public Output<string> VpcId { get; private set; } = null!;

        /// <summary>
        /// The Region of the VPC.
        /// </summary>
        [Output("vpcRegionId")]
        public Output<string> VpcRegionId { get; private set; } = null!;


        /// <summary>
        /// Create a Endpoint 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 Endpoint(string name, EndpointArgs args, CustomResourceOptions? options = null)
            : base("alicloud:pvtz/endpoint:Endpoint", name, args ?? new EndpointArgs(), MakeResourceOptions(options, ""))
        {
        }

        private Endpoint(string name, Input<string> id, EndpointState? state = null, CustomResourceOptions? options = null)
            : base("alicloud:pvtz/endpoint:Endpoint", 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 Endpoint 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 Endpoint Get(string name, Input<string> id, EndpointState? state = null, CustomResourceOptions? options = null)
        {
            return new Endpoint(name, id, state, options);
        }
    }

    public sealed class EndpointArgs : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// The name of the resource.
        /// </summary>
        [Input("endpointName", required: true)]
        public Input<string> EndpointName { get; set; } = null!;

        [Input("ipConfigs", required: true)]
        private InputList<Inputs.EndpointIpConfigArgs>? _ipConfigs;

        /// <summary>
        /// The Ip Configs. See the following `Block ip_configs`. **NOTE:** In order to ensure high availability, add at least 2 and up to 6.
        /// </summary>
        public InputList<Inputs.EndpointIpConfigArgs> IpConfigs
        {
            get => _ipConfigs ?? (_ipConfigs = new InputList<Inputs.EndpointIpConfigArgs>());
            set => _ipConfigs = value;
        }

        /// <summary>
        /// The ID of the Security Group.
        /// </summary>
        [Input("securityGroupId", required: true)]
        public Input<string> SecurityGroupId { get; set; } = null!;

        /// <summary>
        /// The VPC ID.
        /// </summary>
        [Input("vpcId", required: true)]
        public Input<string> VpcId { get; set; } = null!;

        /// <summary>
        /// The Region of the VPC.
        /// </summary>
        [Input("vpcRegionId", required: true)]
        public Input<string> VpcRegionId { get; set; } = null!;

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

    public sealed class EndpointState : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// The name of the resource.
        /// </summary>
        [Input("endpointName")]
        public Input<string>? EndpointName { get; set; }

        [Input("ipConfigs")]
        private InputList<Inputs.EndpointIpConfigGetArgs>? _ipConfigs;

        /// <summary>
        /// The Ip Configs. See the following `Block ip_configs`. **NOTE:** In order to ensure high availability, add at least 2 and up to 6.
        /// </summary>
        public InputList<Inputs.EndpointIpConfigGetArgs> IpConfigs
        {
            get => _ipConfigs ?? (_ipConfigs = new InputList<Inputs.EndpointIpConfigGetArgs>());
            set => _ipConfigs = value;
        }

        /// <summary>
        /// The ID of the Security Group.
        /// </summary>
        [Input("securityGroupId")]
        public Input<string>? SecurityGroupId { get; set; }

        /// <summary>
        /// The status of the resource. Valid values: `CHANGE_FAILED`, `CHANGE_INIT`, `EXCEPTION`, `FAILED`, `INIT`, `SUCCESS`.
        /// </summary>
        [Input("status")]
        public Input<string>? Status { get; set; }

        /// <summary>
        /// The VPC ID.
        /// </summary>
        [Input("vpcId")]
        public Input<string>? VpcId { get; set; }

        /// <summary>
        /// The Region of the VPC.
        /// </summary>
        [Input("vpcRegionId")]
        public Input<string>? VpcRegionId { get; set; }

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