<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;
using Pulumi;

namespace Lbrlabs.PulumiPackage.Ovh.Me
{
    public static class GetSshKey
    {
        /// <summary>
        /// Use this data source to retrieve information about an SSH key.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using System.Linq;
        /// using Pulumi;
        /// using Ovh = Pulumi.Ovh;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var mykey = Ovh.Me.GetSshKey.Invoke(new()
        ///     {
        ///         KeyName = "mykey",
        ///     });
        /// 
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Task<GetSshKeyResult> InvokeAsync(GetSshKeyArgs args, InvokeOptions? options = null)
            => global::Pulumi.Deployment.Instance.InvokeAsync<GetSshKeyResult>("ovh:Me/getSshKey:getSshKey", args ?? new GetSshKeyArgs(), options.WithDefaults());

        /// <summary>
        /// Use this data source to retrieve information about an SSH key.
        /// 
        /// {{% examples %}}
        /// ## Example Usage
        /// {{% example %}}
        /// 
        /// ```csharp
        /// using System.Collections.Generic;
        /// using System.Linq;
        /// using Pulumi;
        /// using Ovh = Pulumi.Ovh;
        /// 
        /// return await Deployment.RunAsync(() =&gt; 
        /// {
        ///     var mykey = Ovh.Me.GetSshKey.Invoke(new()
        ///     {
        ///         KeyName = "mykey",
        ///     });
        /// 
        /// });
        /// ```
        /// {{% /example %}}
        /// {{% /examples %}}
        /// </summary>
        public static Output<GetSshKeyResult> Invoke(GetSshKeyInvokeArgs args, InvokeOptions? options = null)
            => global::Pulumi.Deployment.Instance.Invoke<GetSshKeyResult>("ovh:Me/getSshKey:getSshKey", args ?? new GetSshKeyInvokeArgs(), options.WithDefaults());
    }


    public sealed class GetSshKeyArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// The name of the SSH key.
        /// </summary>
        [Input("keyName", required: true)]
        public string KeyName { get; set; } = null!;

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

    public sealed class GetSshKeyInvokeArgs : global::Pulumi.InvokeArgs
    {
        /// <summary>
        /// The name of the SSH key.
        /// </summary>
        [Input("keyName", required: true)]
        public Input<string> KeyName { get; set; } = null!;

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


    [OutputType]
    public sealed class GetSshKeyResult
    {
        /// <summary>
        /// True when this public SSH key is used for rescue mode and reinstallations.
        /// </summary>
        public readonly bool Default;
        /// <summary>
        /// The provider-assigned unique ID for this managed resource.
        /// </summary>
        public readonly string Id;
        /// <summary>
        /// The content of the public key.
        /// E.g.: "ssh-ed25519 AAAAC3..."
        /// </summary>
        public readonly string Key;
        /// <summary>
        /// See Argument Reference above.
        /// </summary>
        public readonly string KeyName;

        [OutputConstructor]
        private GetSshKeyResult(
            bool @default,

            string id,

            string key,

            string keyName)
        {
            Default = @default;
            Id = id;
            Key = key;
            KeyName = keyName;
        }
    }
}
