To list your clusters, you can use the Google Cloud console, the Google Cloud CLI, the client library, or the Managed Kafka API. You can't use the open source Apache Kafka API to list a cluster.
Required roles and permissions to list your clusters
To get the permissions that
you need to list your clusters,
ask your administrator to grant you the
Managed Kafka Viewer (roles/managedkafka.viewer) IAM role on your project.
For more information about granting roles, see Manage access to projects, folders, and organizations.
This predefined role contains the permissions required to list your clusters. To see the exact permissions that are required, expand the Required permissions section:
Required permissions
The following permissions are required to list your clusters:
-
List clusters:
managedkafka.clusters.list -
Get cluster details:
managedkafka.clusters.get
You might also be able to get these permissions with custom roles or other predefined roles.
List your clusters
To list all your clusters in a project, follow these steps: