1. Packages
  2. GitHub
  3. API Docs
  4. getSshKeys
GitHub v6.2.2 published on Tuesday, Jun 18, 2024 by Pulumi

github.getSshKeys

Explore with Pulumi AI

github logo
GitHub v6.2.2 published on Tuesday, Jun 18, 2024 by Pulumi

    Use this data source to retrieve information about GitHub’s SSH keys.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as github from "@pulumi/github";
    
    const test = github.getSshKeys({});
    
    import pulumi
    import pulumi_github as github
    
    test = github.get_ssh_keys()
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-github/sdk/v6/go/github"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := github.GetSshKeys(ctx, nil, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Github = Pulumi.Github;
    
    return await Deployment.RunAsync(() => 
    {
        var test = Github.GetSshKeys.Invoke();
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.github.GithubFunctions;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var test = GithubFunctions.getSshKeys();
    
        }
    }
    
    variables:
      test:
        fn::invoke:
          Function: github:getSshKeys
          Arguments: {}
    

    Using getSshKeys

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getSshKeys(opts?: InvokeOptions): Promise<GetSshKeysResult>
    function getSshKeysOutput(opts?: InvokeOptions): Output<GetSshKeysResult>
    def get_ssh_keys(opts: Optional[InvokeOptions] = None) -> GetSshKeysResult
    def get_ssh_keys_output(opts: Optional[InvokeOptions] = None) -> Output[GetSshKeysResult]
    func GetSshKeys(ctx *Context, opts ...InvokeOption) (*GetSshKeysResult, error)
    func GetSshKeysOutput(ctx *Context, opts ...InvokeOption) GetSshKeysResultOutput

    > Note: This function is named GetSshKeys in the Go SDK.

    public static class GetSshKeys 
    {
        public static Task<GetSshKeysResult> InvokeAsync(InvokeOptions? opts = null)
        public static Output<GetSshKeysResult> Invoke(InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetSshKeysResult> getSshKeys(InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: github:index/getSshKeys:getSshKeys
      arguments:
        # arguments dictionary

    getSshKeys Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Keys List<string>
    An array of GitHub's SSH public keys.
    Id string
    The provider-assigned unique ID for this managed resource.
    Keys []string
    An array of GitHub's SSH public keys.
    id String
    The provider-assigned unique ID for this managed resource.
    keys List<String>
    An array of GitHub's SSH public keys.
    id string
    The provider-assigned unique ID for this managed resource.
    keys string[]
    An array of GitHub's SSH public keys.
    id str
    The provider-assigned unique ID for this managed resource.
    keys Sequence[str]
    An array of GitHub's SSH public keys.
    id String
    The provider-assigned unique ID for this managed resource.
    keys List<String>
    An array of GitHub's SSH public keys.

    Package Details

    Repository
    GitHub pulumi/pulumi-github
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the github Terraform Provider.
    github logo
    GitHub v6.2.2 published on Tuesday, Jun 18, 2024 by Pulumi