1. Packages
  2. Confluent Provider
  3. API Docs
  4. getUsers
Confluent v2.10.0 published on Wednesday, Nov 20, 2024 by Pulumi

confluentcloud.getUsers

Explore with Pulumi AI

confluentcloud logo
Confluent v2.10.0 published on Wednesday, Nov 20, 2024 by Pulumi

    General Availability

    confluentcloud.getUsers describes a data source for Users.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as confluentcloud from "@pulumi/confluentcloud";
    
    const main = confluentcloud.getUsers({});
    export const users = main.then(main => main.ids);
    
    import pulumi
    import pulumi_confluentcloud as confluentcloud
    
    main = confluentcloud.get_users()
    pulumi.export("users", main.ids)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-confluentcloud/sdk/v2/go/confluentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		main, err := confluentcloud.GetUsers(ctx, map[string]interface{}{}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("users", main.Ids)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ConfluentCloud = Pulumi.ConfluentCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var main = ConfluentCloud.GetUsers.Invoke();
    
        return new Dictionary<string, object?>
        {
            ["users"] = main.Apply(getUsersResult => getUsersResult.Ids),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.confluentcloud.ConfluentcloudFunctions;
    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 main = ConfluentcloudFunctions.getUsers();
    
            ctx.export("users", main.applyValue(getUsersResult -> getUsersResult.ids()));
        }
    }
    
    variables:
      main:
        fn::invoke:
          Function: confluentcloud:getUsers
          Arguments: {}
    outputs:
      users: ${main.ids}
    

    Using getUsers

    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 getUsers(opts?: InvokeOptions): Promise<GetUsersResult>
    function getUsersOutput(opts?: InvokeOptions): Output<GetUsersResult>
    def get_users(opts: Optional[InvokeOptions] = None) -> GetUsersResult
    def get_users_output(opts: Optional[InvokeOptions] = None) -> Output[GetUsersResult]
    func GetUsers(ctx *Context, opts ...InvokeOption) (*GetUsersResult, error)
    func GetUsersOutput(ctx *Context, opts ...InvokeOption) GetUsersResultOutput

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

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

    getUsers Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Ids List<string>
    (Required List of Strings) The list of User IDs, for example: ["u-abc123", "u-abc124"].
    Id string
    The provider-assigned unique ID for this managed resource.
    Ids []string
    (Required List of Strings) The list of User IDs, for example: ["u-abc123", "u-abc124"].
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    (Required List of Strings) The list of User IDs, for example: ["u-abc123", "u-abc124"].
    id string
    The provider-assigned unique ID for this managed resource.
    ids string[]
    (Required List of Strings) The list of User IDs, for example: ["u-abc123", "u-abc124"].
    id str
    The provider-assigned unique ID for this managed resource.
    ids Sequence[str]
    (Required List of Strings) The list of User IDs, for example: ["u-abc123", "u-abc124"].
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    (Required List of Strings) The list of User IDs, for example: ["u-abc123", "u-abc124"].

    Package Details

    Repository
    Confluent Cloud pulumi/pulumi-confluentcloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the confluent Terraform Provider.
    confluentcloud logo
    Confluent v2.10.0 published on Wednesday, Nov 20, 2024 by Pulumi