google-cloud-functions overview (2.9.0)

com.google.cloud.functions.v1

A client to Cloud Functions API

The interfaces provided are listed below, along with usage samples.

CloudFunctionsServiceClient

Service Description: A service that application uses to manipulate triggers and functions.

Sample for CloudFunctionsServiceClient:


// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try(CloudFunctionsServiceClientcloudFunctionsServiceClient=
CloudFunctionsServiceClient.create()){
CloudFunctionNamename=CloudFunctionName.of("[PROJECT]","[LOCATION]","[FUNCTION]");
CloudFunctionresponse=cloudFunctionsServiceClient.getFunction(name);
}

com.google.cloud.functions.v1.stub

com.google.cloud.functions.v2

A client to Cloud Functions API

The interfaces provided are listed below, along with usage samples.

FunctionServiceClient

Service Description: Google Cloud Functions is used to deploy functions that are executed by Google in response to various events. Data connected with that event is passed to a function as the input data.

A **function** is a resource which describes a function that should be executed and how it is triggered.

Sample for FunctionServiceClient:


// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try(FunctionServiceClientfunctionServiceClient=FunctionServiceClient.create()){
FunctionNamename=FunctionName.of("[PROJECT]","[LOCATION]","[FUNCTION]");
Functionresponse=functionServiceClient.getFunction(name);
}

com.google.cloud.functions.v2.stub

com.google.cloud.functions.v2alpha

A client to Cloud Functions API

The interfaces provided are listed below, along with usage samples.

FunctionServiceClient

Service Description: Google Cloud Functions is used to deploy functions that are executed by Google in response to various events. Data connected with that event is passed to a function as the input data.

A **function** is a resource which describes a function that should be executed and how it is triggered.

Sample for FunctionServiceClient:


// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try(FunctionServiceClientfunctionServiceClient=FunctionServiceClient.create()){
FunctionNamename=FunctionName.of("[PROJECT]","[LOCATION]","[FUNCTION]");
Functionresponse=functionServiceClient.getFunction(name);
}

com.google.cloud.functions.v2alpha.stub

com.google.cloud.functions.v2beta

A client to Cloud Functions API

The interfaces provided are listed below, along with usage samples.

FunctionServiceClient

Service Description: Google Cloud Functions is used to deploy functions that are executed by Google in response to various events. Data connected with that event is passed to a function as the input data.

A **function** is a resource which describes a function that should be executed and how it is triggered.

Sample for FunctionServiceClient:


// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try(FunctionServiceClientfunctionServiceClient=FunctionServiceClient.create()){
FunctionNamename=FunctionName.of("[PROJECT]","[LOCATION]","[FUNCTION]");
Functionresponse=functionServiceClient.getFunction(name);
}

com.google.cloud.functions.v2beta.stub

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.