# 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 json
import warnings
import pulumi
import pulumi.runtime
from typing import Union
from .. import utilities, tables

class GetGroupResult:
    """
    A collection of values returned by getGroup.
    """
    def __init__(__self__, arn=None, group_id=None, group_name=None, id=None, path=None, users=None):
        if arn and not isinstance(arn, str):
            raise TypeError("Expected argument 'arn' to be a str")
        __self__.arn = arn
        """
        The Amazon Resource Name (ARN) specifying the iam user.
        """
        if group_id and not isinstance(group_id, str):
            raise TypeError("Expected argument 'group_id' to be a str")
        __self__.group_id = group_id
        """
        The stable and unique string identifying the group.
        """
        if group_name and not isinstance(group_name, str):
            raise TypeError("Expected argument 'group_name' to be a str")
        __self__.group_name = group_name
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        __self__.id = id
        """
        The provider-assigned unique ID for this managed resource.
        """
        if path and not isinstance(path, str):
            raise TypeError("Expected argument 'path' to be a str")
        __self__.path = path
        """
        The path to the iam user.
        """
        if users and not isinstance(users, list):
            raise TypeError("Expected argument 'users' to be a list")
        __self__.users = users
        """
        List of objects containing group member information. See supported fields below.
        """
class AwaitableGetGroupResult(GetGroupResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetGroupResult(
            arn=self.arn,
            group_id=self.group_id,
            group_name=self.group_name,
            id=self.id,
            path=self.path,
            users=self.users)

def get_group(group_name=None,opts=None):
    """
    This data source can be used to fetch information about a specific
    IAM group. By using this data source, you can reference IAM group
    properties without having to hard code ARNs as input.

    ## Example Usage



    ```python
    import pulumi
    import pulumi_aws as aws

    example = aws.iam.get_group(group_name="an_example_group_name")
    ```



    :param str group_name: The friendly IAM group name to match.
    """
    __args__ = dict()


    __args__['groupName'] = group_name
    if opts is None:
        opts = pulumi.InvokeOptions()
    if opts.version is None:
        opts.version = utilities.get_version()
    __ret__ = pulumi.runtime.invoke('aws:iam/getGroup:getGroup', __args__, opts=opts).value

    return AwaitableGetGroupResult(
        arn=__ret__.get('arn'),
        group_id=__ret__.get('groupId'),
        group_name=__ret__.get('groupName'),
        id=__ret__.get('id'),
        path=__ret__.get('path'),
        users=__ret__.get('users'))
