Note:
This documentation is for version3.32.0of the library.
Some samples may not work with other versions.
Installation
Install theGoogle.Cloud.Container.V1package from NuGet. Add it to
your project in the normal way (for example by right-clicking on the
project in Visual Studio and choosing "Manage NuGet Packages...").
Authentication
When running on Google Cloud, no action needs to be taken to authenticate.
Otherwise, the simplest way of authenticating your API calls is to
set up Application Default Credentials.
The credentials will automatically be used to authenticate. SeeSet up Application Default Credentialsfor more details.
ClusterManagerClient client = ClusterManagerClient.Create();
// You can list clusters in a single zone, or specify "-" for all zones.
LocationName location = new LocationName(projectId, locationId: "-");
ListClustersResponse zones = client.ListClusters(location.ToString());
foreach (Cluster cluster in zones.Clusters)
{
Console.WriteLine($"Cluster {cluster.Name} in {cluster.Location}");
}
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[[["\u003cp\u003eThis webpage provides documentation for version 3.32.0 of the \u003ccode\u003eGoogle.Cloud.Container.V1\u003c/code\u003e .NET client library, which interfaces with the Google Kubernetes Engine API.\u003c/p\u003e\n"],["\u003cp\u003eThe library offers easy installation via NuGet, and it automatically authenticates when running on Google Cloud, or through Application Default Credentials when not on Google Cloud.\u003c/p\u003e\n"],["\u003cp\u003eThe documentation contains links to various versions of the library, including the latest version (3.33.0), and it outlines how to use the \u003ccode\u003eClusterManagerClient\u003c/code\u003e for all operations.\u003c/p\u003e\n"],["\u003cp\u003eThe page includes sample code demonstrating how to list clusters using the \u003ccode\u003eClusterManagerClient\u003c/code\u003e, showing how to specify a location and iterate through the returned clusters.\u003c/p\u003e\n"],["\u003cp\u003eThere are a total of 38 different versions of the library listed, ranging from the latest (3.33.0) back to 2.3.0.\u003c/p\u003e\n"]]],[],null,[]]