Method: projects.locations.functions.call

Synchronously invokes a deployed Cloud Function. To be used for testing purposes as very limited traffic is allowed. For more information on the actual limits, refer to Rate Limits .

HTTP request

POST https://cloudfunctions.googleapis.com/v1/{name}:call

Path parameters

Parameters
name

string

Required. The name of the function to be called. It takes the form projects/{project}/locations/{location}/functions/{function} .

Authorization requires the following IAM permission on the specified resource name :

  • cloudfunctions.functions.call

Request body

The request body contains data with the following structure:

JSON representation
 { 
 "data" 
 : 
 string 
 } 
Fields
data

string

Required. Input to be passed to the function.

Response body

Response of functions.call method.

If successful, the response body contains data with the following structure:

JSON representation
 { 
 "executionId" 
 : 
 string 
 , 
 "result" 
 : 
 string 
 , 
 "error" 
 : 
 string 
 } 
Fields
execution Id

string

Execution id of function invocation.

result

string

Result populated for successful execution of synchronous function. Will not be populated if function does not return a result through context.

error

string

Either system or user-function generated error. Set if execution was not successful.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview .

Design a Mobile Site
View Site in Mobile | Classic
Share by: