# 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 builtins
import copy
import warnings
import sys
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
if sys.version_info >= (3, 11):
    from typing import NotRequired, TypedDict, TypeAlias
else:
    from typing_extensions import NotRequired, TypedDict, TypeAlias
from .. import _utilities
from . import outputs

__all__ = [
    'GetTrafficMirrorSessionResult',
    'AwaitableGetTrafficMirrorSessionResult',
    'get_traffic_mirror_session',
    'get_traffic_mirror_session_output',
]

@pulumi.output_type
class GetTrafficMirrorSessionResult:
    """
    A collection of values returned by getTrafficMirrorSession.
    """
    def __init__(__self__, business_status=None, created_time=None, description=None, id=None, lock_reason=None, network_interface_id=None, packet_length=None, priority=None, project_name=None, status=None, tags=None, traffic_mirror_filter_id=None, traffic_mirror_session_id=None, traffic_mirror_session_name=None, traffic_mirror_source_ids=None, traffic_mirror_target_id=None, virtual_network_id=None):
        if business_status and not isinstance(business_status, str):
            raise TypeError("Expected argument 'business_status' to be a str")
        pulumi.set(__self__, "business_status", business_status)
        if created_time and not isinstance(created_time, str):
            raise TypeError("Expected argument 'created_time' to be a str")
        pulumi.set(__self__, "created_time", created_time)
        if description and not isinstance(description, str):
            raise TypeError("Expected argument 'description' to be a str")
        pulumi.set(__self__, "description", description)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if lock_reason and not isinstance(lock_reason, str):
            raise TypeError("Expected argument 'lock_reason' to be a str")
        pulumi.set(__self__, "lock_reason", lock_reason)
        if network_interface_id and not isinstance(network_interface_id, str):
            raise TypeError("Expected argument 'network_interface_id' to be a str")
        pulumi.set(__self__, "network_interface_id", network_interface_id)
        if packet_length and not isinstance(packet_length, int):
            raise TypeError("Expected argument 'packet_length' to be a int")
        pulumi.set(__self__, "packet_length", packet_length)
        if priority and not isinstance(priority, int):
            raise TypeError("Expected argument 'priority' to be a int")
        pulumi.set(__self__, "priority", priority)
        if project_name and not isinstance(project_name, str):
            raise TypeError("Expected argument 'project_name' to be a str")
        pulumi.set(__self__, "project_name", project_name)
        if status and not isinstance(status, str):
            raise TypeError("Expected argument 'status' to be a str")
        pulumi.set(__self__, "status", status)
        if tags and not isinstance(tags, list):
            raise TypeError("Expected argument 'tags' to be a list")
        pulumi.set(__self__, "tags", tags)
        if traffic_mirror_filter_id and not isinstance(traffic_mirror_filter_id, str):
            raise TypeError("Expected argument 'traffic_mirror_filter_id' to be a str")
        pulumi.set(__self__, "traffic_mirror_filter_id", traffic_mirror_filter_id)
        if traffic_mirror_session_id and not isinstance(traffic_mirror_session_id, str):
            raise TypeError("Expected argument 'traffic_mirror_session_id' to be a str")
        pulumi.set(__self__, "traffic_mirror_session_id", traffic_mirror_session_id)
        if traffic_mirror_session_name and not isinstance(traffic_mirror_session_name, str):
            raise TypeError("Expected argument 'traffic_mirror_session_name' to be a str")
        pulumi.set(__self__, "traffic_mirror_session_name", traffic_mirror_session_name)
        if traffic_mirror_source_ids and not isinstance(traffic_mirror_source_ids, list):
            raise TypeError("Expected argument 'traffic_mirror_source_ids' to be a list")
        pulumi.set(__self__, "traffic_mirror_source_ids", traffic_mirror_source_ids)
        if traffic_mirror_target_id and not isinstance(traffic_mirror_target_id, str):
            raise TypeError("Expected argument 'traffic_mirror_target_id' to be a str")
        pulumi.set(__self__, "traffic_mirror_target_id", traffic_mirror_target_id)
        if virtual_network_id and not isinstance(virtual_network_id, int):
            raise TypeError("Expected argument 'virtual_network_id' to be a int")
        pulumi.set(__self__, "virtual_network_id", virtual_network_id)

    @property
    @pulumi.getter(name="businessStatus")
    def business_status(self) -> builtins.str:
        """
        会话计费状态。Normal：正常计费中。  - FinancialLocked：欠费锁定。
        """
        return pulumi.get(self, "business_status")

    @property
    @pulumi.getter(name="createdTime")
    def created_time(self) -> builtins.str:
        """
        创建时间。
        """
        return pulumi.get(self, "created_time")

    @property
    @pulumi.getter
    def description(self) -> builtins.str:
        """
        镜像会话实例描述。
        """
        return pulumi.get(self, "description")

    @property
    @pulumi.getter
    def id(self) -> builtins.str:
        """
        Uniquely identifies the resource.
        """
        return pulumi.get(self, "id")

    @property
    @pulumi.getter(name="lockReason")
    def lock_reason(self) -> builtins.str:
        """
        锁定原因。
        """
        return pulumi.get(self, "lock_reason")

    @property
    @pulumi.getter(name="networkInterfaceId")
    def network_interface_id(self) -> builtins.str:
        """
        镜像源实例ID，当前只支持ECS的主网卡和辅助网卡。
        """
        return pulumi.get(self, "network_interface_id")

    @property
    @pulumi.getter(name="packetLength")
    def packet_length(self) -> builtins.int:
        """
        镜像会话MTU，超过被截断，取值范围：64～9600。
        """
        return pulumi.get(self, "packet_length")

    @property
    @pulumi.getter
    def priority(self) -> builtins.int:
        """
        镜像会话优先级，取值范围1 ～ 32766，同一账户下镜像会话优先级不能重复。
        """
        return pulumi.get(self, "priority")

    @property
    @pulumi.getter(name="projectName")
    def project_name(self) -> builtins.str:
        """
        所属项目的名称
        """
        return pulumi.get(self, "project_name")

    @property
    @pulumi.getter
    def status(self) -> builtins.str:
        """
        会话状态。
        """
        return pulumi.get(self, "status")

    @property
    @pulumi.getter
    def tags(self) -> Sequence['outputs.GetTrafficMirrorSessionTagResult']:
        """
        标签信息。
        """
        return pulumi.get(self, "tags")

    @property
    @pulumi.getter(name="trafficMirrorFilterId")
    def traffic_mirror_filter_id(self) -> builtins.str:
        """
        筛选条件实例ID。
        """
        return pulumi.get(self, "traffic_mirror_filter_id")

    @property
    @pulumi.getter(name="trafficMirrorSessionId")
    def traffic_mirror_session_id(self) -> builtins.str:
        """
        镜像会话实例ID。
        """
        return pulumi.get(self, "traffic_mirror_session_id")

    @property
    @pulumi.getter(name="trafficMirrorSessionName")
    def traffic_mirror_session_name(self) -> builtins.str:
        """
        镜像会话名称。
        """
        return pulumi.get(self, "traffic_mirror_session_name")

    @property
    @pulumi.getter(name="trafficMirrorSourceIds")
    def traffic_mirror_source_ids(self) -> Sequence[builtins.str]:
        """
        镜像源实例列表。
        """
        return pulumi.get(self, "traffic_mirror_source_ids")

    @property
    @pulumi.getter(name="trafficMirrorTargetId")
    def traffic_mirror_target_id(self) -> builtins.str:
        """
        镜像目的实例ID。
        """
        return pulumi.get(self, "traffic_mirror_target_id")

    @property
    @pulumi.getter(name="virtualNetworkId")
    def virtual_network_id(self) -> builtins.int:
        """
        镜像会话VNI，取值范围1 ～ 16777215。
        """
        return pulumi.get(self, "virtual_network_id")


class AwaitableGetTrafficMirrorSessionResult(GetTrafficMirrorSessionResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetTrafficMirrorSessionResult(
            business_status=self.business_status,
            created_time=self.created_time,
            description=self.description,
            id=self.id,
            lock_reason=self.lock_reason,
            network_interface_id=self.network_interface_id,
            packet_length=self.packet_length,
            priority=self.priority,
            project_name=self.project_name,
            status=self.status,
            tags=self.tags,
            traffic_mirror_filter_id=self.traffic_mirror_filter_id,
            traffic_mirror_session_id=self.traffic_mirror_session_id,
            traffic_mirror_session_name=self.traffic_mirror_session_name,
            traffic_mirror_source_ids=self.traffic_mirror_source_ids,
            traffic_mirror_target_id=self.traffic_mirror_target_id,
            virtual_network_id=self.virtual_network_id)


def get_traffic_mirror_session(id: Optional[builtins.str] = None,
                               opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetTrafficMirrorSessionResult:
    """
    Data Source schema for Byteplus::VPC::TrafficMirrorSession


    :param builtins.str id: Uniquely identifies the resource.
    """
    __args__ = dict()
    __args__['id'] = id
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('bytepluscc:vpc/getTrafficMirrorSession:getTrafficMirrorSession', __args__, opts=opts, typ=GetTrafficMirrorSessionResult).value

    return AwaitableGetTrafficMirrorSessionResult(
        business_status=pulumi.get(__ret__, 'business_status'),
        created_time=pulumi.get(__ret__, 'created_time'),
        description=pulumi.get(__ret__, 'description'),
        id=pulumi.get(__ret__, 'id'),
        lock_reason=pulumi.get(__ret__, 'lock_reason'),
        network_interface_id=pulumi.get(__ret__, 'network_interface_id'),
        packet_length=pulumi.get(__ret__, 'packet_length'),
        priority=pulumi.get(__ret__, 'priority'),
        project_name=pulumi.get(__ret__, 'project_name'),
        status=pulumi.get(__ret__, 'status'),
        tags=pulumi.get(__ret__, 'tags'),
        traffic_mirror_filter_id=pulumi.get(__ret__, 'traffic_mirror_filter_id'),
        traffic_mirror_session_id=pulumi.get(__ret__, 'traffic_mirror_session_id'),
        traffic_mirror_session_name=pulumi.get(__ret__, 'traffic_mirror_session_name'),
        traffic_mirror_source_ids=pulumi.get(__ret__, 'traffic_mirror_source_ids'),
        traffic_mirror_target_id=pulumi.get(__ret__, 'traffic_mirror_target_id'),
        virtual_network_id=pulumi.get(__ret__, 'virtual_network_id'))
def get_traffic_mirror_session_output(id: Optional[pulumi.Input[builtins.str]] = None,
                                      opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetTrafficMirrorSessionResult]:
    """
    Data Source schema for Byteplus::VPC::TrafficMirrorSession


    :param builtins.str id: Uniquely identifies the resource.
    """
    __args__ = dict()
    __args__['id'] = id
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('bytepluscc:vpc/getTrafficMirrorSession:getTrafficMirrorSession', __args__, opts=opts, typ=GetTrafficMirrorSessionResult)
    return __ret__.apply(lambda __response__: GetTrafficMirrorSessionResult(
        business_status=pulumi.get(__response__, 'business_status'),
        created_time=pulumi.get(__response__, 'created_time'),
        description=pulumi.get(__response__, 'description'),
        id=pulumi.get(__response__, 'id'),
        lock_reason=pulumi.get(__response__, 'lock_reason'),
        network_interface_id=pulumi.get(__response__, 'network_interface_id'),
        packet_length=pulumi.get(__response__, 'packet_length'),
        priority=pulumi.get(__response__, 'priority'),
        project_name=pulumi.get(__response__, 'project_name'),
        status=pulumi.get(__response__, 'status'),
        tags=pulumi.get(__response__, 'tags'),
        traffic_mirror_filter_id=pulumi.get(__response__, 'traffic_mirror_filter_id'),
        traffic_mirror_session_id=pulumi.get(__response__, 'traffic_mirror_session_id'),
        traffic_mirror_session_name=pulumi.get(__response__, 'traffic_mirror_session_name'),
        traffic_mirror_source_ids=pulumi.get(__response__, 'traffic_mirror_source_ids'),
        traffic_mirror_target_id=pulumi.get(__response__, 'traffic_mirror_target_id'),
        virtual_network_id=pulumi.get(__response__, 'virtual_network_id')))
