# coding=utf-8
# *** WARNING: this file was generated by pulumi-language-python. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import builtins as _builtins
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

__all__ = [
    'GetSecurityGroupResult',
    'AwaitableGetSecurityGroupResult',
    'get_security_group',
    'get_security_group_output',
]

@pulumi.output_type
class GetSecurityGroupResult:
    """
    A collection of values returned by getSecurityGroup.
    """
    def __init__(__self__, description=None, id=None, is_read_only=None, name=None, propogate_to_apic=None, value=None):
        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 is_read_only and not isinstance(is_read_only, bool):
            raise TypeError("Expected argument 'is_read_only' to be a bool")
        pulumi.set(__self__, "is_read_only", is_read_only)
        if name and not isinstance(name, str):
            raise TypeError("Expected argument 'name' to be a str")
        pulumi.set(__self__, "name", name)
        if propogate_to_apic and not isinstance(propogate_to_apic, bool):
            raise TypeError("Expected argument 'propogate_to_apic' to be a bool")
        pulumi.set(__self__, "propogate_to_apic", propogate_to_apic)
        if value and not isinstance(value, int):
            raise TypeError("Expected argument 'value' to be a int")
        pulumi.set(__self__, "value", value)

    @_builtins.property
    @pulumi.getter
    def description(self) -> _builtins.str:
        """
        Description
        """
        return pulumi.get(self, "description")

    @_builtins.property
    @pulumi.getter
    def id(self) -> _builtins.str:
        """
        The id of the object
        """
        return pulumi.get(self, "id")

    @_builtins.property
    @pulumi.getter(name="isReadOnly")
    def is_read_only(self) -> _builtins.bool:
        """
        Read-only
        """
        return pulumi.get(self, "is_read_only")

    @_builtins.property
    @pulumi.getter
    def name(self) -> _builtins.str:
        """
        The name of the security group
        """
        return pulumi.get(self, "name")

    @_builtins.property
    @pulumi.getter(name="propogateToApic")
    def propogate_to_apic(self) -> _builtins.bool:
        """
        Propagate to APIC (ACI)
        """
        return pulumi.get(self, "propogate_to_apic")

    @_builtins.property
    @pulumi.getter
    def value(self) -> _builtins.int:
        """
        `-1` to auto-generate
        """
        return pulumi.get(self, "value")


class AwaitableGetSecurityGroupResult(GetSecurityGroupResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetSecurityGroupResult(
            description=self.description,
            id=self.id,
            is_read_only=self.is_read_only,
            name=self.name,
            propogate_to_apic=self.propogate_to_apic,
            value=self.value)


def get_security_group(id: Optional[_builtins.str] = None,
                       name: Optional[_builtins.str] = None,
                       opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetSecurityGroupResult:
    """
    This data source can read the TrustSec Security Group.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_ise as ise

    example = ise.trustsec.get_security_group(id="76d24097-41c4-4558-a4d0-a8c07ac08470")
    ```


    :param _builtins.str id: The id of the object
    :param _builtins.str name: The name of the security group
    """
    __args__ = dict()
    __args__['id'] = id
    __args__['name'] = name
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('ise:trustsec/getSecurityGroup:getSecurityGroup', __args__, opts=opts, typ=GetSecurityGroupResult).value

    return AwaitableGetSecurityGroupResult(
        description=pulumi.get(__ret__, 'description'),
        id=pulumi.get(__ret__, 'id'),
        is_read_only=pulumi.get(__ret__, 'is_read_only'),
        name=pulumi.get(__ret__, 'name'),
        propogate_to_apic=pulumi.get(__ret__, 'propogate_to_apic'),
        value=pulumi.get(__ret__, 'value'))
def get_security_group_output(id: Optional[pulumi.Input[Optional[_builtins.str]]] = None,
                              name: Optional[pulumi.Input[Optional[_builtins.str]]] = None,
                              opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetSecurityGroupResult]:
    """
    This data source can read the TrustSec Security Group.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_ise as ise

    example = ise.trustsec.get_security_group(id="76d24097-41c4-4558-a4d0-a8c07ac08470")
    ```


    :param _builtins.str id: The id of the object
    :param _builtins.str name: The name of the security group
    """
    __args__ = dict()
    __args__['id'] = id
    __args__['name'] = name
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('ise:trustsec/getSecurityGroup:getSecurityGroup', __args__, opts=opts, typ=GetSecurityGroupResult)
    return __ret__.apply(lambda __response__: GetSecurityGroupResult(
        description=pulumi.get(__response__, 'description'),
        id=pulumi.get(__response__, 'id'),
        is_read_only=pulumi.get(__response__, 'is_read_only'),
        name=pulumi.get(__response__, 'name'),
        propogate_to_apic=pulumi.get(__response__, 'propogate_to_apic'),
        value=pulumi.get(__response__, 'value')))
