// *** 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! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;
using Pulumi;

namespace zscaler.PulumiPackage.Zia.AdminUsers
{
    public static class GetAdminUsers
    {
        /// <summary>
        /// Use the **zia_admin_users** data source to get information about an admin user account created in the Zscaler Internet Access cloud or via the API. This data source can then be associated with a ZIA administrator role.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using Zia = Pulumi.Zia;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var johnDoe = Zia.AdminUsers.GetAdminUsers.Invoke(new()
        ///     {
        ///         LoginName = "dycjh@example.com",
        ///     });
        /// 
        /// });
        /// ```
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using Zia = Pulumi.Zia;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var johnDoe = Zia.AdminUsers.GetAdminUsers.Invoke(new()
        ///     {
        ///         Username = "John Doe",
        ///     });
        /// 
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Task<GetAdminUsersResult> InvokeAsync(GetAdminUsersArgs? args = null, InvokeOptions? options = null)
            => global::Pulumi.Deployment.Instance.InvokeAsync<GetAdminUsersResult>("zia:AdminUsers/getAdminUsers:getAdminUsers", args ?? new GetAdminUsersArgs(), options.WithDefaults());

        /// <summary>
        /// Use the **zia_admin_users** data source to get information about an admin user account created in the Zscaler Internet Access cloud or via the API. This data source can then be associated with a ZIA administrator role.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using Zia = Pulumi.Zia;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var johnDoe = Zia.AdminUsers.GetAdminUsers.Invoke(new()
        ///     {
        ///         LoginName = "dycjh@example.com",
        ///     });
        /// 
        /// });
        /// ```
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using Zia = Pulumi.Zia;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var johnDoe = Zia.AdminUsers.GetAdminUsers.Invoke(new()
        ///     {
        ///         Username = "John Doe",
        ///     });
        /// 
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Output<GetAdminUsersResult> Invoke(GetAdminUsersInvokeArgs? args = null, InvokeOptions? options = null)
            => global::Pulumi.Deployment.Instance.Invoke<GetAdminUsersResult>("zia:AdminUsers/getAdminUsers:getAdminUsers", args ?? new GetAdminUsersInvokeArgs(), options.WithDefaults());
    }


    public sealed class GetAdminUsersArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// The ID of the admin user to be exported.
        /// </summary>
        [Input("id")]
        public int? Id { get; set; }

        /// <summary>
        /// The email address of the admin user to be exported.
        /// </summary>
        [Input("loginName")]
        public string? LoginName { get; set; }

        /// <summary>
        /// The username of the admin user to be exported.
        /// </summary>
        [Input("username")]
        public string? Username { get; set; }

        public GetAdminUsersArgs()
        {
        }
        public static new GetAdminUsersArgs Empty => new GetAdminUsersArgs();
    }

    public sealed class GetAdminUsersInvokeArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// The ID of the admin user to be exported.
        /// </summary>
        [Input("id")]
        public Input<int>? Id { get; set; }

        /// <summary>
        /// The email address of the admin user to be exported.
        /// </summary>
        [Input("loginName")]
        public Input<string>? LoginName { get; set; }

        /// <summary>
        /// The username of the admin user to be exported.
        /// </summary>
        [Input("username")]
        public Input<string>? Username { get; set; }

        public GetAdminUsersInvokeArgs()
        {
        }
        public static new GetAdminUsersInvokeArgs Empty => new GetAdminUsersInvokeArgs();
    }


    [OutputType]
    public sealed class GetAdminUsersResult
    {
        /// <summary>
        /// (Set of Object) The admin's scope. Only applicable for the LOCATION_GROUP admin scope type, in which case this attribute gives the list of ID/name pairs of locations within the location group.
        /// </summary>
        public readonly ImmutableArray<Outputs.GetAdminUsersAdminScopeResult> AdminScopes;
        /// <summary>
        /// (String) Additional information about the admin or auditor.
        /// </summary>
        public readonly string Comments;
        /// <summary>
        /// (Boolean) Indicates whether or not the admin account is disabled.
        /// </summary>
        public readonly bool Disabled;
        /// <summary>
        /// (String) Admin or auditor's email address.
        /// </summary>
        public readonly string Email;
        /// <summary>
        /// (List of Object)
        /// </summary>
        public readonly ImmutableArray<Outputs.GetAdminUsersExecMobileAppTokenResult> ExecMobileAppTokens;
        /// <summary>
        /// (Number) Identifier that uniquely identifies an entity
        /// </summary>
        public readonly int Id;
        /// <summary>
        /// (Boolean) Indicates whether the user is an auditor. This attribute is subject to change.
        /// </summary>
        public readonly bool IsAuditor;
        /// <summary>
        /// (Boolean) Indicates whether or not Executive Insights App access is enabled for the admin.
        /// </summary>
        public readonly bool IsExecMobileAppEnabled;
        /// <summary>
        /// (Boolean) Indicates whether or not the admin can be edited or deleted.
        /// </summary>
        public readonly bool IsNonEditable;
        /// <summary>
        /// (Boolean) Indicates whether or not an admin's password has expired.
        /// </summary>
        public readonly bool IsPasswordExpired;
        /// <summary>
        /// (Boolean) The default is true when SAML Authentication is disabled. When SAML Authentication is enabled, this can be set to false in order to force the admin to login via SSO only.
        /// </summary>
        public readonly bool IsPasswordLoginAllowed;
        /// <summary>
        /// (Boolean) Communication setting for Product Update.
        /// </summary>
        public readonly bool IsProductUpdateCommEnabled;
        /// <summary>
        /// (Boolean) Communication for Security Report is enabled.
        /// </summary>
        public readonly bool IsSecurityReportCommEnabled;
        /// <summary>
        /// (Boolean) Communication setting for Service Update.
        /// </summary>
        public readonly bool IsServiceUpdateCommEnabled;
        public readonly string LoginName;
        public readonly int PwdLastModifiedTime;
        /// <summary>
        /// (Set of Object) Role of the admin. This is not required for an auditor.
        /// </summary>
        public readonly ImmutableArray<Outputs.GetAdminUsersRoleResult> Roles;
        public readonly string Username;

        [OutputConstructor]
        private GetAdminUsersResult(
            ImmutableArray<Outputs.GetAdminUsersAdminScopeResult> adminScopes,

            string comments,

            bool disabled,

            string email,

            ImmutableArray<Outputs.GetAdminUsersExecMobileAppTokenResult> execMobileAppTokens,

            int id,

            bool isAuditor,

            bool isExecMobileAppEnabled,

            bool isNonEditable,

            bool isPasswordExpired,

            bool isPasswordLoginAllowed,

            bool isProductUpdateCommEnabled,

            bool isSecurityReportCommEnabled,

            bool isServiceUpdateCommEnabled,

            string loginName,

            int pwdLastModifiedTime,

            ImmutableArray<Outputs.GetAdminUsersRoleResult> roles,

            string username)
        {
            AdminScopes = adminScopes;
            Comments = comments;
            Disabled = disabled;
            Email = email;
            ExecMobileAppTokens = execMobileAppTokens;
            Id = id;
            IsAuditor = isAuditor;
            IsExecMobileAppEnabled = isExecMobileAppEnabled;
            IsNonEditable = isNonEditable;
            IsPasswordExpired = isPasswordExpired;
            IsPasswordLoginAllowed = isPasswordLoginAllowed;
            IsProductUpdateCommEnabled = isProductUpdateCommEnabled;
            IsSecurityReportCommEnabled = isSecurityReportCommEnabled;
            IsServiceUpdateCommEnabled = isServiceUpdateCommEnabled;
            LoginName = loginName;
            PwdLastModifiedTime = pwdLastModifiedTime;
            Roles = roles;
            Username = username;
        }
    }
}
