<gh_stars>0// *** 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;

namespace Pulumi.AliCloud.CS
{
    public static class GetRegistryEnterpriseInstances
    {
        /// <summary>
        /// This data source provides a list Container Registry Enterprise Edition instances on Alibaba Cloud.
        /// 
        /// &gt; **NOTE:** Available in v1.86.0+
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using AliCloud = Pulumi.AliCloud;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var myInstances = AliCloud.CS.GetRegistryEnterpriseInstances.Invoke(new()
        ///     {
        ///         NameRegex = "my-instances",
        ///         OutputFile = "my-instances-json",
        ///     });
        /// 
        ///     return new Dictionary&lt;string, object?&gt;
        ///     {
        ///         ["output"] = myInstances.Apply(getRegistryEnterpriseInstancesResult =&gt; getRegistryEnterpriseInstancesResult.Instances),
        ///     };
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Task<GetRegistryEnterpriseInstancesResult> InvokeAsync(GetRegistryEnterpriseInstancesArgs? args = null, InvokeOptions? options = null)
            => Pulumi.Deployment.Instance.InvokeAsync<GetRegistryEnterpriseInstancesResult>("alicloud:cs/getRegistryEnterpriseInstances:getRegistryEnterpriseInstances", args ?? new GetRegistryEnterpriseInstancesArgs(), options.WithDefaults());

        /// <summary>
        /// This data source provides a list Container Registry Enterprise Edition instances on Alibaba Cloud.
        /// 
        /// &gt; **NOTE:** Available in v1.86.0+
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using Pulumi;
        /// using AliCloud = Pulumi.AliCloud;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var myInstances = AliCloud.CS.GetRegistryEnterpriseInstances.Invoke(new()
        ///     {
        ///         NameRegex = "my-instances",
        ///         OutputFile = "my-instances-json",
        ///     });
        /// 
        ///     return new Dictionary&lt;string, object?&gt;
        ///     {
        ///         ["output"] = myInstances.Apply(getRegistryEnterpriseInstancesResult =&gt; getRegistryEnterpriseInstancesResult.Instances),
        ///     };
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Output<GetRegistryEnterpriseInstancesResult> Invoke(GetRegistryEnterpriseInstancesInvokeArgs? args = null, InvokeOptions? options = null)
            => Pulumi.Deployment.Instance.Invoke<GetRegistryEnterpriseInstancesResult>("alicloud:cs/getRegistryEnterpriseInstances:getRegistryEnterpriseInstances", args ?? new GetRegistryEnterpriseInstancesInvokeArgs(), options.WithDefaults());
    }


    public sealed class GetRegistryEnterpriseInstancesArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// Default to `true`. Set it to true can output instance authorization token.
        /// </summary>
        [Input("enableDetails")]
        public bool? EnableDetails { get; set; }

        [Input("ids")]
        private List<string>? _ids;

        /// <summary>
        /// A list of ids to filter results by instance id.
        /// </summary>
        public List<string> Ids
        {
            get => _ids ?? (_ids = new List<string>());
            set => _ids = value;
        }

        /// <summary>
        /// A regex string to filter results by instance name.
        /// </summary>
        [Input("nameRegex")]
        public string? NameRegex { get; set; }

        [Input("outputFile")]
        public string? OutputFile { get; set; }

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

    public sealed class GetRegistryEnterpriseInstancesInvokeArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// Default to `true`. Set it to true can output instance authorization token.
        /// </summary>
        [Input("enableDetails")]
        public Input<bool>? EnableDetails { get; set; }

        [Input("ids")]
        private InputList<string>? _ids;

        /// <summary>
        /// A list of ids to filter results by instance id.
        /// </summary>
        public InputList<string> Ids
        {
            get => _ids ?? (_ids = new InputList<string>());
            set => _ids = value;
        }

        /// <summary>
        /// A regex string to filter results by instance name.
        /// </summary>
        [Input("nameRegex")]
        public Input<string>? NameRegex { get; set; }

        [Input("outputFile")]
        public Input<string>? OutputFile { get; set; }

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


    [OutputType]
    public sealed class GetRegistryEnterpriseInstancesResult
    {
        public readonly bool? EnableDetails;
        /// <summary>
        /// The provider-assigned unique ID for this managed resource.
        /// </summary>
        public readonly string Id;
        /// <summary>
        /// A list of matched Container Registry Enterprise Edition instances. Its element is an instance uuid.
        /// </summary>
        public readonly ImmutableArray<string> Ids;
        /// <summary>
        /// A list of matched Container Registry Enterprise Editioninstances. Each element contains the following attributes:
        /// </summary>
        public readonly ImmutableArray<Outputs.GetRegistryEnterpriseInstancesInstanceResult> Instances;
        public readonly string? NameRegex;
        /// <summary>
        /// A list of instance names.
        /// </summary>
        public readonly ImmutableArray<string> Names;
        public readonly string? OutputFile;

        [OutputConstructor]
        private GetRegistryEnterpriseInstancesResult(
            bool? enableDetails,

            string id,

            ImmutableArray<string> ids,

            ImmutableArray<Outputs.GetRegistryEnterpriseInstancesInstanceResult> instances,

            string? nameRegex,

            ImmutableArray<string> names,

            string? outputFile)
        {
            EnableDetails = enableDetails;
            Id = id;
            Ids = ids;
            Instances = instances;
            NameRegex = nameRegex;
            Names = names;
            OutputFile = outputFile;
        }
    }
}
