<reponame>zscaler/pulumi-zia// *** 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.Users
{
    public static class GetUserManagement
    {
        /// <summary>
        /// Use the **zia_user_management** data source to get information about a user account that may have been created in the Zscaler Internet Access portal or via API. This data source can then be associated with a ZIA cloud firewall filtering rule, and URL filtering rules.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using Zia = Pulumi.Zia;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var adamAshcroft = Zia.Users.GetUserManagement.Invoke(new()
        ///     {
        ///         Name = "Adam Ashcroft",
        ///     });
        /// 
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Task<GetUserManagementResult> InvokeAsync(GetUserManagementArgs? args = null, InvokeOptions? options = null)
            => global::Pulumi.Deployment.Instance.InvokeAsync<GetUserManagementResult>("zia:Users/getUserManagement:getUserManagement", args ?? new GetUserManagementArgs(), options.WithDefaults());

        /// <summary>
        /// Use the **zia_user_management** data source to get information about a user account that may have been created in the Zscaler Internet Access portal or via API. This data source can then be associated with a ZIA cloud firewall filtering rule, and URL filtering rules.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using Zia = Pulumi.Zia;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var adamAshcroft = Zia.Users.GetUserManagement.Invoke(new()
        ///     {
        ///         Name = "Adam Ashcroft",
        ///     });
        /// 
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Output<GetUserManagementResult> Invoke(GetUserManagementInvokeArgs? args = null, InvokeOptions? options = null)
            => global::Pulumi.Deployment.Instance.Invoke<GetUserManagementResult>("zia:Users/getUserManagement:getUserManagement", args ?? new GetUserManagementInvokeArgs(), options.WithDefaults());
    }


    public sealed class GetUserManagementArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// The ID of the time window resource.
        /// </summary>
        [Input("id")]
        public int? Id { get; set; }

        /// <summary>
        /// User name. This appears when choosing users for policies.
        /// </summary>
        [Input("name")]
        public string? Name { get; set; }

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

    public sealed class GetUserManagementInvokeArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// The ID of the time window resource.
        /// </summary>
        [Input("id")]
        public Input<int>? Id { get; set; }

        /// <summary>
        /// User name. This appears when choosing users for policies.
        /// </summary>
        [Input("name")]
        public Input<string>? Name { get; set; }

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


    [OutputType]
    public sealed class GetUserManagementResult
    {
        /// <summary>
        /// (Optional) True if this user is an Admin user. readOnly: `true` default: `false`
        /// </summary>
        public readonly bool AdminUser;
        /// <summary>
        /// (String) Additional information about the group
        /// </summary>
        public readonly string Comments;
        /// <summary>
        /// (Required) Department a user belongs to
        /// </summary>
        public readonly ImmutableArray<Outputs.GetUserManagementDepartmentResult> Departments;
        /// <summary>
        /// (Required) User email consists of a user name and domain name. It does not have to be a valid email address, but it must be unique and its domain must belong to the organization
        /// </summary>
        public readonly string Email;
        /// <summary>
        /// (Required) List of Groups a user belongs to. Groups are used in policies.
        /// </summary>
        public readonly ImmutableArray<Outputs.GetUserManagementGroupResult> Groups;
        /// <summary>
        /// (Number) Unique identfier for the group
        /// </summary>
        public readonly int? Id;
        public readonly string IsAuditor;
        /// <summary>
        /// (String) Group name
        /// </summary>
        public readonly string? Name;
        /// <summary>
        /// (String) Temporary Authentication Email. If you enabled one-time tokens or links, enter the email address to which the Zscaler service sends the tokens or links. If this is empty, the service will send the email to the User email.
        /// </summary>
        public readonly string TempAuthEmail;
        /// <summary>
        /// (String) User type. Provided only if this user is not an end user. The supported types are:
        /// </summary>
        public readonly string Type;

        [OutputConstructor]
        private GetUserManagementResult(
            bool adminUser,

            string comments,

            ImmutableArray<Outputs.GetUserManagementDepartmentResult> departments,

            string email,

            ImmutableArray<Outputs.GetUserManagementGroupResult> groups,

            int? id,

            string isAuditor,

            string? name,

            string tempAuthEmail,

            string type)
        {
            AdminUser = adminUser;
            Comments = comments;
            Departments = departments;
            Email = email;
            Groups = groups;
            Id = id;
            IsAuditor = isAuditor;
            Name = name;
            TempAuthEmail = tempAuthEmail;
            Type = type;
        }
    }
}
