1. Packages
  2. Packages
  3. Ionoscloud
  4. API Docs
  5. getKafkaUsers
Viewing docs for IonosCloud v0.3.0
published on Wednesday, Apr 15, 2026 by ionos-cloud
ionoscloud logo
Viewing docs for IonosCloud v0.3.0
published on Wednesday, Apr 15, 2026 by ionos-cloud

    The Kafka users data source can be used to retrieve information about users.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ionoscloud from "@ionos-cloud/sdk-pulumi";
    
    const kafkaUsersDs = ionoscloud.getKafkaUsers({
        clusterId: "kafka_cluster_id",
        location: "kafka_cluster_location",
        timeouts: {
            read: "1s",
        },
    });
    
    import pulumi
    import pulumi_ionoscloud as ionoscloud
    
    kafka_users_ds = ionoscloud.get_kafka_users(cluster_id="kafka_cluster_id",
        location="kafka_cluster_location",
        timeouts={
            "read": "1s",
        })
    
    package main
    
    import (
    	"github.com/ionos-cloud/pulumi-ionoscloud/sdk/go/ionoscloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ionoscloud.GetKafkaUsers(ctx, &ionoscloud.GetKafkaUsersArgs{
    			ClusterId: "kafka_cluster_id",
    			Location:  pulumi.StringRef("kafka_cluster_location"),
    			Timeouts: ionoscloud.GetKafkaUsersTimeouts{
    				Read: pulumi.StringRef("1s"),
    			},
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ionoscloud = Ionoscloud.Pulumi.Ionoscloud;
    
    return await Deployment.RunAsync(() => 
    {
        var kafkaUsersDs = Ionoscloud.Index.GetKafkaUsers.Invoke(new()
        {
            ClusterId = "kafka_cluster_id",
            Location = "kafka_cluster_location",
            Timeouts = new Ionoscloud.Inputs.GetKafkaUsersTimeoutsInputArgs
            {
                Read = "1s",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ionoscloud.IonoscloudFunctions;
    import com.pulumi.ionoscloud.inputs.GetKafkaUsersArgs;
    import com.pulumi.ionoscloud.inputs.GetKafkaUsersTimeoutsArgs;
    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 kafkaUsersDs = IonoscloudFunctions.getKafkaUsers(GetKafkaUsersArgs.builder()
                .clusterId("kafka_cluster_id")
                .location("kafka_cluster_location")
                .timeouts(GetKafkaUsersTimeoutsArgs.builder()
                    .read("1s")
                    .build())
                .build());
    
        }
    }
    
    variables:
      kafkaUsersDs:
        fn::invoke:
          function: ionoscloud:getKafkaUsers
          arguments:
            clusterId: kafka_cluster_id
            location: kafka_cluster_location
            timeouts:
              read: 1s
    
    Example coming soon!
    

    Using getKafkaUsers

    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 getKafkaUsers(args: GetKafkaUsersArgs, opts?: InvokeOptions): Promise<GetKafkaUsersResult>
    function getKafkaUsersOutput(args: GetKafkaUsersOutputArgs, opts?: InvokeOptions): Output<GetKafkaUsersResult>
    def get_kafka_users(cluster_id: Optional[str] = None,
                        location: Optional[str] = None,
                        timeouts: Optional[GetKafkaUsersTimeouts] = None,
                        opts: Optional[InvokeOptions] = None) -> GetKafkaUsersResult
    def get_kafka_users_output(cluster_id: pulumi.Input[Optional[str]] = None,
                        location: pulumi.Input[Optional[str]] = None,
                        timeouts: pulumi.Input[Optional[GetKafkaUsersTimeoutsArgs]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetKafkaUsersResult]
    func GetKafkaUsers(ctx *Context, args *GetKafkaUsersArgs, opts ...InvokeOption) (*GetKafkaUsersResult, error)
    func GetKafkaUsersOutput(ctx *Context, args *GetKafkaUsersOutputArgs, opts ...InvokeOption) GetKafkaUsersResultOutput

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

    public static class GetKafkaUsers 
    {
        public static Task<GetKafkaUsersResult> InvokeAsync(GetKafkaUsersArgs args, InvokeOptions? opts = null)
        public static Output<GetKafkaUsersResult> Invoke(GetKafkaUsersInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetKafkaUsersResult> getKafkaUsers(GetKafkaUsersArgs args, InvokeOptions options)
    public static Output<GetKafkaUsersResult> getKafkaUsers(GetKafkaUsersArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ionoscloud:index/getKafkaUsers:getKafkaUsers
      arguments:
        # arguments dictionary
    data "ionoscloud_getkafkausers" "name" {
        # arguments
    }

    The following arguments are supported:

    ClusterId string
    [string] the ID of the Kafka cluster;
    Location string
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    Timeouts Ionoscloud.GetKafkaUsersTimeouts
    ClusterId string
    [string] the ID of the Kafka cluster;
    Location string
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    Timeouts GetKafkaUsersTimeouts
    cluster_id string
    [string] the ID of the Kafka cluster;
    location string
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    timeouts object
    clusterId String
    [string] the ID of the Kafka cluster;
    location String
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    timeouts GetKafkaUsersTimeouts
    clusterId string
    [string] the ID of the Kafka cluster;
    location string
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    timeouts GetKafkaUsersTimeouts
    cluster_id str
    [string] the ID of the Kafka cluster;
    location str
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    timeouts GetKafkaUsersTimeouts
    clusterId String
    [string] the ID of the Kafka cluster;
    location String
    [string] the location of the Kafka cluster, can be one of: de/fra, de/fra/2, de/txl, fr/par, es/vit, gb/lhr, gb/bhx, us/las, us/mci, us/ewr. If omitted, the default location will be used: de/fra;
    timeouts Property Map

    getKafkaUsers Result

    The following output properties are available:

    ClusterId string
    Id string
    The provider-assigned unique ID for this managed resource.
    Users List<Ionoscloud.GetKafkaUsersUser>
    the list of users, for each user inside the list, the following information is retrieved:
    Location string
    Timeouts Ionoscloud.GetKafkaUsersTimeouts
    ClusterId string
    Id string
    The provider-assigned unique ID for this managed resource.
    Users []GetKafkaUsersUser
    the list of users, for each user inside the list, the following information is retrieved:
    Location string
    Timeouts GetKafkaUsersTimeouts
    cluster_id string
    id string
    The provider-assigned unique ID for this managed resource.
    users list(object)
    the list of users, for each user inside the list, the following information is retrieved:
    location string
    timeouts object
    clusterId String
    id String
    The provider-assigned unique ID for this managed resource.
    users List<GetKafkaUsersUser>
    the list of users, for each user inside the list, the following information is retrieved:
    location String
    timeouts GetKafkaUsersTimeouts
    clusterId string
    id string
    The provider-assigned unique ID for this managed resource.
    users GetKafkaUsersUser[]
    the list of users, for each user inside the list, the following information is retrieved:
    location string
    timeouts GetKafkaUsersTimeouts
    cluster_id str
    id str
    The provider-assigned unique ID for this managed resource.
    users Sequence[GetKafkaUsersUser]
    the list of users, for each user inside the list, the following information is retrieved:
    location str
    timeouts GetKafkaUsersTimeouts
    clusterId String
    id String
    The provider-assigned unique ID for this managed resource.
    users List<Property Map>
    the list of users, for each user inside the list, the following information is retrieved:
    location String
    timeouts Property Map

    Supporting Types

    GetKafkaUsersTimeouts

    Read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    Read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read String
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read str
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read String
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).

    GetKafkaUsersUser

    Id string
    the ID of the user;
    Username string
    the name of the user;
    Id string
    the ID of the user;
    Username string
    the name of the user;
    id string
    the ID of the user;
    username string
    the name of the user;
    id String
    the ID of the user;
    username String
    the name of the user;
    id string
    the ID of the user;
    username string
    the name of the user;
    id str
    the ID of the user;
    username str
    the name of the user;
    id String
    the ID of the user;
    username String
    the name of the user;

    Package Details

    Repository
    ionoscloud ionos-cloud/pulumi-ionoscloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ionoscloud Terraform Provider.
    ionoscloud logo
    Viewing docs for IonosCloud v0.3.0
    published on Wednesday, Apr 15, 2026 by ionos-cloud
      Try Pulumi Cloud free. Your team will thank you.