// *** 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.Aviatrix
{
    /// <summary>
    /// The **aviatrix_aws_tgw_connect_peer** resource allows the creation and management of AWS TGW Connect peers. This
    /// resource is available as of provider version R2.18.1+.
    /// 
    /// ## Example Usage
    /// 
    /// ```csharp
    /// using System.Collections.Generic;
    /// using Pulumi;
    /// using Aviatrix = Pulumi.Aviatrix;
    /// 
    /// return await Deployment.RunAsync(() =&gt; 
    /// {
    ///     // Create an Aviatrix AWS TGW Connect Peer
    ///     var test = new Aviatrix.AviatrixAwsTgwConnectPeer("test", new()
    ///     {
    ///         TgwName = aviatrix_aws_tgw.Test_aws_tgw.Tgw_name,
    ///         ConnectionName = aviatrix_aws_tgw_connect.Test_aws_tgw_connect.Connection_name,
    ///         ConnectPeerName = "connect-peer-test",
    ///         ConnectAttachmentId = aviatrix_aws_tgw_connect.Test_aws_tgw_connect.Connect_attachment_id,
    ///         PeerAsNumber = "65001",
    ///         PeerGreAddress = "172.31.1.11",
    ///         BgpInsideCidrs = new[]
    ///         {
    ///             "169.254.6.0/29",
    ///         },
    ///         TgwGreAddress = "10.0.0.32",
    ///     });
    /// 
    /// });
    /// ```
    /// 
    /// ## Import
    /// 
    /// **aws_tgw_connect_peer** can be imported using the `tgw_name`, `connection_name` and `connect_peer_name`, e.g.
    /// 
    /// ```sh
    ///  $ pulumi import aviatrix:index/aviatrixAwsTgwConnectPeer:AviatrixAwsTgwConnectPeer test tgw_name~~connection_name~~connect_peer_name
    /// ```
    /// </summary>
    [AviatrixResourceType("aviatrix:index/aviatrixAwsTgwConnectPeer:AviatrixAwsTgwConnectPeer")]
    public partial class AviatrixAwsTgwConnectPeer : global::Pulumi.CustomResource
    {
        /// <summary>
        /// Set of BGP Inside CIDR Block(s).
        /// </summary>
        [Output("bgpInsideCidrs")]
        public Output<ImmutableArray<string>> BgpInsideCidrs { get; private set; } = null!;

        /// <summary>
        /// Connect Attachment ID.
        /// </summary>
        [Output("connectAttachmentId")]
        public Output<string> ConnectAttachmentId { get; private set; } = null!;

        /// <summary>
        /// Connect Peer ID.
        /// </summary>
        [Output("connectPeerId")]
        public Output<string> ConnectPeerId { get; private set; } = null!;

        /// <summary>
        /// TGW Connect peer name.
        /// </summary>
        [Output("connectPeerName")]
        public Output<string> ConnectPeerName { get; private set; } = null!;

        /// <summary>
        /// TGW Connect connection name.
        /// </summary>
        [Output("connectionName")]
        public Output<string> ConnectionName { get; private set; } = null!;

        /// <summary>
        /// Peer AS Number.
        /// </summary>
        [Output("peerAsNumber")]
        public Output<string> PeerAsNumber { get; private set; } = null!;

        /// <summary>
        /// Peer GRE IP Address.
        /// </summary>
        [Output("peerGreAddress")]
        public Output<string> PeerGreAddress { get; private set; } = null!;

        /// <summary>
        /// AWS TGW GRE IP Address.
        /// </summary>
        [Output("tgwGreAddress")]
        public Output<string?> TgwGreAddress { get; private set; } = null!;

        /// <summary>
        /// AWS TGW name.
        /// </summary>
        [Output("tgwName")]
        public Output<string> TgwName { get; private set; } = null!;


        /// <summary>
        /// Create a AviatrixAwsTgwConnectPeer 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 AviatrixAwsTgwConnectPeer(string name, AviatrixAwsTgwConnectPeerArgs args, CustomResourceOptions? options = null)
            : base("aviatrix:index/aviatrixAwsTgwConnectPeer:AviatrixAwsTgwConnectPeer", name, args ?? new AviatrixAwsTgwConnectPeerArgs(), MakeResourceOptions(options, ""))
        {
        }

        private AviatrixAwsTgwConnectPeer(string name, Input<string> id, AviatrixAwsTgwConnectPeerState? state = null, CustomResourceOptions? options = null)
            : base("aviatrix:index/aviatrixAwsTgwConnectPeer:AviatrixAwsTgwConnectPeer", 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/astipkovits",
            };
            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 AviatrixAwsTgwConnectPeer 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 AviatrixAwsTgwConnectPeer Get(string name, Input<string> id, AviatrixAwsTgwConnectPeerState? state = null, CustomResourceOptions? options = null)
        {
            return new AviatrixAwsTgwConnectPeer(name, id, state, options);
        }
    }

    public sealed class AviatrixAwsTgwConnectPeerArgs : global::Pulumi.ResourceArgs
    {
        [Input("bgpInsideCidrs", required: true)]
        private InputList<string>? _bgpInsideCidrs;

        /// <summary>
        /// Set of BGP Inside CIDR Block(s).
        /// </summary>
        public InputList<string> BgpInsideCidrs
        {
            get => _bgpInsideCidrs ?? (_bgpInsideCidrs = new InputList<string>());
            set => _bgpInsideCidrs = value;
        }

        /// <summary>
        /// Connect Attachment ID.
        /// </summary>
        [Input("connectAttachmentId", required: true)]
        public Input<string> ConnectAttachmentId { get; set; } = null!;

        /// <summary>
        /// TGW Connect peer name.
        /// </summary>
        [Input("connectPeerName", required: true)]
        public Input<string> ConnectPeerName { get; set; } = null!;

        /// <summary>
        /// TGW Connect connection name.
        /// </summary>
        [Input("connectionName", required: true)]
        public Input<string> ConnectionName { get; set; } = null!;

        /// <summary>
        /// Peer AS Number.
        /// </summary>
        [Input("peerAsNumber", required: true)]
        public Input<string> PeerAsNumber { get; set; } = null!;

        /// <summary>
        /// Peer GRE IP Address.
        /// </summary>
        [Input("peerGreAddress", required: true)]
        public Input<string> PeerGreAddress { get; set; } = null!;

        /// <summary>
        /// AWS TGW GRE IP Address.
        /// </summary>
        [Input("tgwGreAddress")]
        public Input<string>? TgwGreAddress { get; set; }

        /// <summary>
        /// AWS TGW name.
        /// </summary>
        [Input("tgwName", required: true)]
        public Input<string> TgwName { get; set; } = null!;

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

    public sealed class AviatrixAwsTgwConnectPeerState : global::Pulumi.ResourceArgs
    {
        [Input("bgpInsideCidrs")]
        private InputList<string>? _bgpInsideCidrs;

        /// <summary>
        /// Set of BGP Inside CIDR Block(s).
        /// </summary>
        public InputList<string> BgpInsideCidrs
        {
            get => _bgpInsideCidrs ?? (_bgpInsideCidrs = new InputList<string>());
            set => _bgpInsideCidrs = value;
        }

        /// <summary>
        /// Connect Attachment ID.
        /// </summary>
        [Input("connectAttachmentId")]
        public Input<string>? ConnectAttachmentId { get; set; }

        /// <summary>
        /// Connect Peer ID.
        /// </summary>
        [Input("connectPeerId")]
        public Input<string>? ConnectPeerId { get; set; }

        /// <summary>
        /// TGW Connect peer name.
        /// </summary>
        [Input("connectPeerName")]
        public Input<string>? ConnectPeerName { get; set; }

        /// <summary>
        /// TGW Connect connection name.
        /// </summary>
        [Input("connectionName")]
        public Input<string>? ConnectionName { get; set; }

        /// <summary>
        /// Peer AS Number.
        /// </summary>
        [Input("peerAsNumber")]
        public Input<string>? PeerAsNumber { get; set; }

        /// <summary>
        /// Peer GRE IP Address.
        /// </summary>
        [Input("peerGreAddress")]
        public Input<string>? PeerGreAddress { get; set; }

        /// <summary>
        /// AWS TGW GRE IP Address.
        /// </summary>
        [Input("tgwGreAddress")]
        public Input<string>? TgwGreAddress { get; set; }

        /// <summary>
        /// AWS TGW name.
        /// </summary>
        [Input("tgwName")]
        public Input<string>? TgwName { get; set; }

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