// *** 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.ApiGateway
{
    public static class GetApiKeys
    {
        /// <summary>
        /// Use this data source to query API gateway access keys.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using Pulumi;
        /// using Tencentcloud = Pulumi.Tencentcloud;
        /// using Tencentcloud = TencentCloudIAC.PulumiPackage.Tencentcloud;
        /// 
        /// class MyStack : Stack
        /// {
        ///     public MyStack()
        ///     {
        ///         var test = new Tencentcloud.ApiGateway.ApiKey("test", new Tencentcloud.ApiGateway.ApiKeyArgs
        ///         {
        ///             SecretName = "my_api_key",
        ///             Status = "on",
        ///         });
        ///         var name = Tencentcloud.ApiGateway.GetApiKeys.Invoke(new Tencentcloud.ApiGateway.GetApiKeysInvokeArgs
        ///         {
        ///             SecretName = test.SecretName,
        ///         });
        ///         var id = Tencentcloud.ApiGateway.GetApiKeys.Invoke(new Tencentcloud.ApiGateway.GetApiKeysInvokeArgs
        ///         {
        ///             ApiKeyId = test.Id,
        ///         });
        ///     }
        /// 
        /// }
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Task<GetApiKeysResult> InvokeAsync(GetApiKeysArgs? args = null, InvokeOptions? options = null)
            => Pulumi.Deployment.Instance.InvokeAsync<GetApiKeysResult>("tencentcloud:ApiGateway/getApiKeys:getApiKeys", args ?? new GetApiKeysArgs(), options.WithDefaults());

        /// <summary>
        /// Use this data source to query API gateway access keys.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using Pulumi;
        /// using Tencentcloud = Pulumi.Tencentcloud;
        /// using Tencentcloud = TencentCloudIAC.PulumiPackage.Tencentcloud;
        /// 
        /// class MyStack : Stack
        /// {
        ///     public MyStack()
        ///     {
        ///         var test = new Tencentcloud.ApiGateway.ApiKey("test", new Tencentcloud.ApiGateway.ApiKeyArgs
        ///         {
        ///             SecretName = "my_api_key",
        ///             Status = "on",
        ///         });
        ///         var name = Tencentcloud.ApiGateway.GetApiKeys.Invoke(new Tencentcloud.ApiGateway.GetApiKeysInvokeArgs
        ///         {
        ///             SecretName = test.SecretName,
        ///         });
        ///         var id = Tencentcloud.ApiGateway.GetApiKeys.Invoke(new Tencentcloud.ApiGateway.GetApiKeysInvokeArgs
        ///         {
        ///             ApiKeyId = test.Id,
        ///         });
        ///     }
        /// 
        /// }
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Output<GetApiKeysResult> Invoke(GetApiKeysInvokeArgs? args = null, InvokeOptions? options = null)
            => Pulumi.Deployment.Instance.Invoke<GetApiKeysResult>("tencentcloud:ApiGateway/getApiKeys:getApiKeys", args ?? new GetApiKeysInvokeArgs(), options.WithDefaults());
    }


    public sealed class GetApiKeysArgs : Pulumi.InvokeArgs
    {
        /// <summary>
        /// Created API key ID, this field is exactly the same as ID.
        /// </summary>
        [Input("apiKeyId")]
        public string? ApiKeyId { get; set; }

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

        /// <summary>
        /// Custom key name.
        /// </summary>
        [Input("secretName")]
        public string? SecretName { get; set; }

        public GetApiKeysArgs()
        {
        }
    }

    public sealed class GetApiKeysInvokeArgs : Pulumi.InvokeArgs
    {
        /// <summary>
        /// Created API key ID, this field is exactly the same as ID.
        /// </summary>
        [Input("apiKeyId")]
        public Input<string>? ApiKeyId { get; set; }

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

        /// <summary>
        /// Custom key name.
        /// </summary>
        [Input("secretName")]
        public Input<string>? SecretName { get; set; }

        public GetApiKeysInvokeArgs()
        {
        }
    }


    [OutputType]
    public sealed class GetApiKeysResult
    {
        /// <summary>
        /// API key ID.
        /// </summary>
        public readonly string? ApiKeyId;
        /// <summary>
        /// The provider-assigned unique ID for this managed resource.
        /// </summary>
        public readonly string Id;
        /// <summary>
        /// A list of API keys.
        /// </summary>
        public readonly ImmutableArray<Outputs.GetApiKeysListResult> Lists;
        public readonly string? ResultOutputFile;
        public readonly string? SecretName;

        [OutputConstructor]
        private GetApiKeysResult(
            string? apiKeyId,

            string id,

            ImmutableArray<Outputs.GetApiKeysListResult> lists,

            string? resultOutputFile,

            string? secretName)
        {
            ApiKeyId = apiKeyId;
            Id = id;
            Lists = lists;
            ResultOutputFile = resultOutputFile;
            SecretName = secretName;
        }
    }
}
