# coding=utf-8
# *** 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! ***

import copy
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from .. import _utilities
from . import outputs
from ._inputs import *

__all__ = [
    'GetConnectResult',
    'AwaitableGetConnectResult',
    'get_connect',
    'get_connect_output',
]

@pulumi.output_type
class GetConnectResult:
    """
    A collection of values returned by getConnect.
    """
    def __init__(__self__, filters=None, id=None, protocol=None, tags=None, transit_gateway_connect_id=None, transit_gateway_id=None, transport_attachment_id=None):
        if filters and not isinstance(filters, list):
            raise TypeError("Expected argument 'filters' to be a list")
        pulumi.set(__self__, "filters", filters)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if protocol and not isinstance(protocol, str):
            raise TypeError("Expected argument 'protocol' to be a str")
        pulumi.set(__self__, "protocol", protocol)
        if tags and not isinstance(tags, dict):
            raise TypeError("Expected argument 'tags' to be a dict")
        pulumi.set(__self__, "tags", tags)
        if transit_gateway_connect_id and not isinstance(transit_gateway_connect_id, str):
            raise TypeError("Expected argument 'transit_gateway_connect_id' to be a str")
        pulumi.set(__self__, "transit_gateway_connect_id", transit_gateway_connect_id)
        if transit_gateway_id and not isinstance(transit_gateway_id, str):
            raise TypeError("Expected argument 'transit_gateway_id' to be a str")
        pulumi.set(__self__, "transit_gateway_id", transit_gateway_id)
        if transport_attachment_id and not isinstance(transport_attachment_id, str):
            raise TypeError("Expected argument 'transport_attachment_id' to be a str")
        pulumi.set(__self__, "transport_attachment_id", transport_attachment_id)

    @property
    @pulumi.getter
    def filters(self) -> Optional[Sequence['outputs.GetConnectFilterResult']]:
        return pulumi.get(self, "filters")

    @property
    @pulumi.getter
    def id(self) -> str:
        """
        The provider-assigned unique ID for this managed resource.
        """
        return pulumi.get(self, "id")

    @property
    @pulumi.getter
    def protocol(self) -> str:
        """
        Tunnel protocol
        """
        return pulumi.get(self, "protocol")

    @property
    @pulumi.getter
    def tags(self) -> Mapping[str, str]:
        """
        Key-value tags for the EC2 Transit Gateway Connect
        """
        return pulumi.get(self, "tags")

    @property
    @pulumi.getter(name="transitGatewayConnectId")
    def transit_gateway_connect_id(self) -> str:
        return pulumi.get(self, "transit_gateway_connect_id")

    @property
    @pulumi.getter(name="transitGatewayId")
    def transit_gateway_id(self) -> str:
        """
        EC2 Transit Gateway identifier
        """
        return pulumi.get(self, "transit_gateway_id")

    @property
    @pulumi.getter(name="transportAttachmentId")
    def transport_attachment_id(self) -> str:
        """
        The underlaying VPC attachment
        """
        return pulumi.get(self, "transport_attachment_id")


class AwaitableGetConnectResult(GetConnectResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetConnectResult(
            filters=self.filters,
            id=self.id,
            protocol=self.protocol,
            tags=self.tags,
            transit_gateway_connect_id=self.transit_gateway_connect_id,
            transit_gateway_id=self.transit_gateway_id,
            transport_attachment_id=self.transport_attachment_id)


def get_connect(filters: Optional[Sequence[pulumi.InputType['GetConnectFilterArgs']]] = None,
                tags: Optional[Mapping[str, str]] = None,
                transit_gateway_connect_id: Optional[str] = None,
                opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetConnectResult:
    """
    Get information on an EC2 Transit Gateway Connect.

    ## Example Usage
    ### By Filter

    ```python
    import pulumi
    import pulumi_aws as aws

    example = aws.ec2transitgateway.get_connect(filters=[aws.ec2transitgateway.GetConnectFilterArgs(
        name="transport-transit-gateway-attachment-id",
        values=["tgw-attach-12345678"],
    )])
    ```
    ### By Identifier

    ```python
    import pulumi
    import pulumi_aws as aws

    example = aws.ec2transitgateway.get_connect(transit_gateway_connect_id="tgw-attach-12345678")
    ```


    :param Sequence[pulumi.InputType['GetConnectFilterArgs']] filters: One or more configuration blocks containing name-values filters. Detailed below.
    :param Mapping[str, str] tags: Key-value tags for the EC2 Transit Gateway Connect
    :param str transit_gateway_connect_id: Identifier of the EC2 Transit Gateway Connect.
    """
    __args__ = dict()
    __args__['filters'] = filters
    __args__['tags'] = tags
    __args__['transitGatewayConnectId'] = transit_gateway_connect_id
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('aws:ec2transitgateway/getConnect:getConnect', __args__, opts=opts, typ=GetConnectResult).value

    return AwaitableGetConnectResult(
        filters=__ret__.filters,
        id=__ret__.id,
        protocol=__ret__.protocol,
        tags=__ret__.tags,
        transit_gateway_connect_id=__ret__.transit_gateway_connect_id,
        transit_gateway_id=__ret__.transit_gateway_id,
        transport_attachment_id=__ret__.transport_attachment_id)


@_utilities.lift_output_func(get_connect)
def get_connect_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi.InputType['GetConnectFilterArgs']]]]] = None,
                       tags: Optional[pulumi.Input[Optional[Mapping[str, str]]]] = None,
                       transit_gateway_connect_id: Optional[pulumi.Input[Optional[str]]] = None,
                       opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetConnectResult]:
    """
    Get information on an EC2 Transit Gateway Connect.

    ## Example Usage
    ### By Filter

    ```python
    import pulumi
    import pulumi_aws as aws

    example = aws.ec2transitgateway.get_connect(filters=[aws.ec2transitgateway.GetConnectFilterArgs(
        name="transport-transit-gateway-attachment-id",
        values=["tgw-attach-12345678"],
    )])
    ```
    ### By Identifier

    ```python
    import pulumi
    import pulumi_aws as aws

    example = aws.ec2transitgateway.get_connect(transit_gateway_connect_id="tgw-attach-12345678")
    ```


    :param Sequence[pulumi.InputType['GetConnectFilterArgs']] filters: One or more configuration blocks containing name-values filters. Detailed below.
    :param Mapping[str, str] tags: Key-value tags for the EC2 Transit Gateway Connect
    :param str transit_gateway_connect_id: Identifier of the EC2 Transit Gateway Connect.
    """
    ...
