# 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
from . import outputs
from ._inputs import *

__all__ = [
    'GetOrganizationUserGroupMemberListResult',
    'AwaitableGetOrganizationUserGroupMemberListResult',
    'get_organization_user_group_member_list',
    'get_organization_user_group_member_list_output',
]

@pulumi.output_type
class GetOrganizationUserGroupMemberListResult:
    """
    A collection of values returned by getOrganizationUserGroupMemberList.
    """
    def __init__(__self__, id=None, members=None, organization_id=None, timeouts=None, user_group_id=None):
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if members and not isinstance(members, list):
            raise TypeError("Expected argument 'members' to be a list")
        pulumi.set(__self__, "members", members)
        if organization_id and not isinstance(organization_id, str):
            raise TypeError("Expected argument 'organization_id' to be a str")
        pulumi.set(__self__, "organization_id", organization_id)
        if timeouts and not isinstance(timeouts, dict):
            raise TypeError("Expected argument 'timeouts' to be a dict")
        pulumi.set(__self__, "timeouts", timeouts)
        if user_group_id and not isinstance(user_group_id, str):
            raise TypeError("Expected argument 'user_group_id' to be a str")
        pulumi.set(__self__, "user_group_id", user_group_id)

    @_builtins.property
    @pulumi.getter
    def id(self) -> _builtins.str:
        """
        Resource ID composed as: `organization_id/user_group_id`.
        """
        return pulumi.get(self, "id")

    @_builtins.property
    @pulumi.getter
    def members(self) -> Optional[Sequence['outputs.GetOrganizationUserGroupMemberListMemberResult']]:
        """
        User group members.
        """
        return pulumi.get(self, "members")

    @_builtins.property
    @pulumi.getter(name="organizationId")
    def organization_id(self) -> _builtins.str:
        """
        ID of an organization.
        """
        return pulumi.get(self, "organization_id")

    @_builtins.property
    @pulumi.getter
    def timeouts(self) -> Optional['outputs.GetOrganizationUserGroupMemberListTimeoutsResult']:
        return pulumi.get(self, "timeouts")

    @_builtins.property
    @pulumi.getter(name="userGroupId")
    def user_group_id(self) -> _builtins.str:
        """
        ID of the user group.
        """
        return pulumi.get(self, "user_group_id")


class AwaitableGetOrganizationUserGroupMemberListResult(GetOrganizationUserGroupMemberListResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetOrganizationUserGroupMemberListResult(
            id=self.id,
            members=self.members,
            organization_id=self.organization_id,
            timeouts=self.timeouts,
            user_group_id=self.user_group_id)


def get_organization_user_group_member_list(members: Optional[Sequence[Union['GetOrganizationUserGroupMemberListMemberArgs', 'GetOrganizationUserGroupMemberListMemberArgsDict']]] = None,
                                            organization_id: Optional[_builtins.str] = None,
                                            timeouts: Optional[Union['GetOrganizationUserGroupMemberListTimeoutsArgs', 'GetOrganizationUserGroupMemberListTimeoutsArgsDict']] = None,
                                            user_group_id: Optional[_builtins.str] = None,
                                            opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetOrganizationUserGroupMemberListResult:
    """
    List members of a user group.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_aiven as aiven

    foo = aiven.get_organization_user_group_member_list(organization_id=organization_id,
        user_group_id=user_group_id)
    ```


    :param Sequence[Union['GetOrganizationUserGroupMemberListMemberArgs', 'GetOrganizationUserGroupMemberListMemberArgsDict']] members: User group members.
    :param _builtins.str organization_id: ID of an organization.
    :param _builtins.str user_group_id: ID of the user group.
    """
    __args__ = dict()
    __args__['members'] = members
    __args__['organizationId'] = organization_id
    __args__['timeouts'] = timeouts
    __args__['userGroupId'] = user_group_id
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('aiven:index/getOrganizationUserGroupMemberList:getOrganizationUserGroupMemberList', __args__, opts=opts, typ=GetOrganizationUserGroupMemberListResult).value

    return AwaitableGetOrganizationUserGroupMemberListResult(
        id=pulumi.get(__ret__, 'id'),
        members=pulumi.get(__ret__, 'members'),
        organization_id=pulumi.get(__ret__, 'organization_id'),
        timeouts=pulumi.get(__ret__, 'timeouts'),
        user_group_id=pulumi.get(__ret__, 'user_group_id'))
def get_organization_user_group_member_list_output(members: Optional[pulumi.Input[Optional[Sequence[Union['GetOrganizationUserGroupMemberListMemberArgs', 'GetOrganizationUserGroupMemberListMemberArgsDict']]]]] = None,
                                                   organization_id: Optional[pulumi.Input[_builtins.str]] = None,
                                                   timeouts: Optional[pulumi.Input[Optional[Union['GetOrganizationUserGroupMemberListTimeoutsArgs', 'GetOrganizationUserGroupMemberListTimeoutsArgsDict']]]] = None,
                                                   user_group_id: Optional[pulumi.Input[_builtins.str]] = None,
                                                   opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetOrganizationUserGroupMemberListResult]:
    """
    List members of a user group.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_aiven as aiven

    foo = aiven.get_organization_user_group_member_list(organization_id=organization_id,
        user_group_id=user_group_id)
    ```


    :param Sequence[Union['GetOrganizationUserGroupMemberListMemberArgs', 'GetOrganizationUserGroupMemberListMemberArgsDict']] members: User group members.
    :param _builtins.str organization_id: ID of an organization.
    :param _builtins.str user_group_id: ID of the user group.
    """
    __args__ = dict()
    __args__['members'] = members
    __args__['organizationId'] = organization_id
    __args__['timeouts'] = timeouts
    __args__['userGroupId'] = user_group_id
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('aiven:index/getOrganizationUserGroupMemberList:getOrganizationUserGroupMemberList', __args__, opts=opts, typ=GetOrganizationUserGroupMemberListResult)
    return __ret__.apply(lambda __response__: GetOrganizationUserGroupMemberListResult(
        id=pulumi.get(__response__, 'id'),
        members=pulumi.get(__response__, 'members'),
        organization_id=pulumi.get(__response__, 'organization_id'),
        timeouts=pulumi.get(__response__, 'timeouts'),
        user_group_id=pulumi.get(__response__, 'user_group_id')))
