Compute Engine client libraries

This page shows how to get started with the Cloud Client Libraries for the Compute Engine API. Read more about the client libraries for Cloud APIs, including the older Google API Client Libraries, in Client Libraries Explained.

Installing the client library

C#

For more information, see Setting Up a C# Development Environment.

Install the Google.Cloud.Compute.V1 package from NuGet.

Go

For more information, see Setting Up a Go Development Environment.

go get cloud.google.com/go/compute/apiv1

Java

For more information, see Setting Up a Java Development Environment.

If you are using Maven, add the following to your pom.xml file. For more information about BOMs, see The Google Cloud Platform Libraries BOM.

<dependency>
  <groupId>com.google.cloud</groupId>
  <artifactId>google-cloud-compute</artifactId>
  <version>1.7.0</version>
</dependency>

If you are using Gradle, add the following to your dependencies:

implementation 'com.google.cloud:google-cloud-compute:1.7.0'

If you are using sbt, add the following to your dependencies:

libraryDependencies += "com.google.cloud" % "google-cloud-compute" % "1.7.0"

The older version of the Cloud Client Libraries for Java for Compute Engine is available as version 0.120.x or earlier in the Maven artifact. Versions 0.120.x and earlier of this library are forward-incompatible with later versions.