<reponame>Dwonczykj/gember_deploy// *** 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 TencentCloudIAC.PulumiPackage.Tencentcloud.Tsf
{
    public static class GetMicroservice
    {
        /// <summary>
        /// Use this data source to query detailed information of tsf microservice
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using Pulumi;
        /// using Tencentcloud = Pulumi.Tencentcloud;
        /// 
        /// class MyStack : Stack
        /// {
        ///     public MyStack()
        ///     {
        ///         var microservice = Output.Create(Tencentcloud.Tsf.GetMicroservice.InvokeAsync(new Tencentcloud.Tsf.GetMicroserviceArgs
        ///         {
        ///             NamespaceId = @var.Namespace_id,
        ///             MicroserviceIdLists = 
        ///             {
        ///                 "ms-yq3jo6jd",
        ///             },
        ///             MicroserviceNameLists = 
        ///             {
        ///                 "provider-demo",
        ///             },
        ///         }));
        ///     }
        /// 
        /// }
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Task<GetMicroserviceResult> InvokeAsync(GetMicroserviceArgs args, InvokeOptions? options = null)
            => Pulumi.Deployment.Instance.InvokeAsync<GetMicroserviceResult>("tencentcloud:Tsf/getMicroservice:getMicroservice", args ?? new GetMicroserviceArgs(), options.WithDefaults());

        /// <summary>
        /// Use this data source to query detailed information of tsf microservice
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using Pulumi;
        /// using Tencentcloud = Pulumi.Tencentcloud;
        /// 
        /// class MyStack : Stack
        /// {
        ///     public MyStack()
        ///     {
        ///         var microservice = Output.Create(Tencentcloud.Tsf.GetMicroservice.InvokeAsync(new Tencentcloud.Tsf.GetMicroserviceArgs
        ///         {
        ///             NamespaceId = @var.Namespace_id,
        ///             MicroserviceIdLists = 
        ///             {
        ///                 "ms-yq3jo6jd",
        ///             },
        ///             MicroserviceNameLists = 
        ///             {
        ///                 "provider-demo",
        ///             },
        ///         }));
        ///     }
        /// 
        /// }
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Output<GetMicroserviceResult> Invoke(GetMicroserviceInvokeArgs args, InvokeOptions? options = null)
            => Pulumi.Deployment.Instance.Invoke<GetMicroserviceResult>("tencentcloud:Tsf/getMicroservice:getMicroservice", args ?? new GetMicroserviceInvokeArgs(), options.WithDefaults());
    }


    public sealed class GetMicroserviceArgs : Pulumi.InvokeArgs
    {
        [Input("microserviceIdLists")]
        private List<string>? _microserviceIdLists;

        /// <summary>
        /// microservice id list.
        /// </summary>
        public List<string> MicroserviceIdLists
        {
            get => _microserviceIdLists ?? (_microserviceIdLists = new List<string>());
            set => _microserviceIdLists = value;
        }

        [Input("microserviceNameLists")]
        private List<string>? _microserviceNameLists;

        /// <summary>
        /// List of service names for search.
        /// </summary>
        public List<string> MicroserviceNameLists
        {
            get => _microserviceNameLists ?? (_microserviceNameLists = new List<string>());
            set => _microserviceNameLists = value;
        }

        /// <summary>
        /// namespace id.
        /// </summary>
        [Input("namespaceId", required: true)]
        public string NamespaceId { get; set; } = null!;

        /// <summary>
        /// Used to save results.
        /// </summary>
        [Input("resultOutputFile")]
        public string? ResultOutputFile { get; set; }

        [Input("statuses")]
        private List<string>? _statuses;

        /// <summary>
        /// status filter, online, offline, single_online.
        /// </summary>
        public List<string> Statuses
        {
            get => _statuses ?? (_statuses = new List<string>());
            set => _statuses = value;
        }

        public GetMicroserviceArgs()
        {
        }
    }

    public sealed class GetMicroserviceInvokeArgs : Pulumi.InvokeArgs
    {
        [Input("microserviceIdLists")]
        private InputList<string>? _microserviceIdLists;

        /// <summary>
        /// microservice id list.
        /// </summary>
        public InputList<string> MicroserviceIdLists
        {
            get => _microserviceIdLists ?? (_microserviceIdLists = new InputList<string>());
            set => _microserviceIdLists = value;
        }

        [Input("microserviceNameLists")]
        private InputList<string>? _microserviceNameLists;

        /// <summary>
        /// List of service names for search.
        /// </summary>
        public InputList<string> MicroserviceNameLists
        {
            get => _microserviceNameLists ?? (_microserviceNameLists = new InputList<string>());
            set => _microserviceNameLists = value;
        }

        /// <summary>
        /// namespace id.
        /// </summary>
        [Input("namespaceId", required: true)]
        public Input<string> NamespaceId { get; set; } = null!;

        /// <summary>
        /// Used to save results.
        /// </summary>
        [Input("resultOutputFile")]
        public Input<string>? ResultOutputFile { get; set; }

        [Input("statuses")]
        private InputList<string>? _statuses;

        /// <summary>
        /// status filter, online, offline, single_online.
        /// </summary>
        public InputList<string> Statuses
        {
            get => _statuses ?? (_statuses = new InputList<string>());
            set => _statuses = value;
        }

        public GetMicroserviceInvokeArgs()
        {
        }
    }


    [OutputType]
    public sealed class GetMicroserviceResult
    {
        /// <summary>
        /// The provider-assigned unique ID for this managed resource.
        /// </summary>
        public readonly string Id;
        public readonly ImmutableArray<string> MicroserviceIdLists;
        public readonly ImmutableArray<string> MicroserviceNameLists;
        /// <summary>
        /// Namespace Id.  Note: This field may return null, indicating that no valid values can be obtained.
        /// </summary>
        public readonly string NamespaceId;
        public readonly string? ResultOutputFile;
        /// <summary>
        /// Microservice paging list information. Note: This field may return null, indicating that no valid value can be obtained.
        /// </summary>
        public readonly ImmutableArray<Outputs.GetMicroserviceResultResult> Results;
        public readonly ImmutableArray<string> Statuses;

        [OutputConstructor]
        private GetMicroserviceResult(
            string id,

            ImmutableArray<string> microserviceIdLists,

            ImmutableArray<string> microserviceNameLists,

            string namespaceId,

            string? resultOutputFile,

            ImmutableArray<Outputs.GetMicroserviceResultResult> results,

            ImmutableArray<string> statuses)
        {
            Id = id;
            MicroserviceIdLists = microserviceIdLists;
            MicroserviceNameLists = microserviceNameLists;
            NamespaceId = namespaceId;
            ResultOutputFile = resultOutputFile;
            Results = results;
            Statuses = statuses;
        }
    }
}
