Google Cloud Functions class
class CloudFunctions
Unbind or remove FirebaseApp.
void resetApp()
Perform the async task repeatedly. Should be places in main loop function.
void loop()
If a function with the given name already exists in the specified project, the long running operation will return ALREADY_EXISTS error.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String create(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Function &function)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function to create.function
- The GoogleCloudFunctions::Function object that holds the information of function to create.
Returns:
String
- The response payload.
If a function with the given name already exists in the specified project, the long running operation will return ALREADY_EXISTS error.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void create(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Function &function, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function to create.function
- The GoogleCloudFunctions::Function object that holds the information of function to create.aResult
- The async result (AsyncResult).
If a function with the given name already exists in the specified project, the long running operation will return ALREADY_EXISTS error.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void create(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Function &function, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function to create.function
- The GoogleCloudFunctions::Function object that holds the information of function to create.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
If a function with the given name already exists in the specified project, the long running operation will return ALREADY_EXISTS error.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location. This is a comma-separated list of fully qualified names of fields. Example: "user.displayName,photo".
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String patch(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Function &function, const String &updateMask)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.function
- The GoogleCloudFunctions::Function object that holds the information of function to update.updateMask
- The list of fields to be updated. If no field mask is provided, all provided fields in the request will be updated.
Returns:
String
- The response payload.
If a function with the given name already exists in the specified project, the long running operation will return ALREADY_EXISTS error.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location. This is a comma-separated list of fully qualified names of fields. Example: "user.displayName,photo".
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void patch(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Function &function, const String &updateMask, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.function
- The GoogleCloudFunctions::Function object that holds the information of function to update.updateMask
- The list of fields to be updated. If no field mask is provided, all provided fields in the request will be updated.aResult
- The async result (AsyncResult).
If a function with the given name already exists in the specified project, the long running operation will return ALREADY_EXISTS error.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location. This is a comma-separated list of fully qualified names of fields. Example: "user.displayName,photo".
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void patch(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Function &function, const String &updateMask, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.function
- The GoogleCloudFunctions::Function object that holds the information of function to update.updateMask
- The list of fields to be updated. If no field mask is provided, all provided fields in the request will be updated.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String deleteFunction(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void deleteFunction(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void deleteFunction(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String list(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, GoogleCloudFunctions::ListOptions &listOptions)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.listOptions
- The GoogleCloudFunctions::ListOptions object that holds the query parameters e.g. pageSize, pageToken, filter, and orderBy.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void list(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, GoogleCloudFunctions::ListOptions &listOptions, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.listOptions
- The GoogleCloudFunctions::ListOptions object that holds the query parameters e.g. pageSize, pageToken, filter, and orderBy.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void list(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, GoogleCloudFunctions::ListOptions &listOptions, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.listOptions
- The GoogleCloudFunctions::ListOptions object that holds the query parameters e.g. pageSize, pageToken, filter, and orderBy.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String get(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void get(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void get(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String call(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, const String &payload)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.payload
- The Input to be passed to the function.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void call(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, const String &payload, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.payload
- The Input to be passed to the function.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void call(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, const String &payload, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.payload
- The Input to be passed to the function.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String generateDownloadURL(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void generateDownloadURL(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void generateDownloadURL(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String generateUploadURL(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::UploadURLOptions options)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::UploadURLOptions object that provides the kmsKeyName and environment options.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void generateUploadURL(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::UploadURLOptions options, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::UploadURLOptions object that provides the kmsKeyName and environment options.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void generateUploadURL(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::UploadURLOptions options, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::UploadURLOptions object that provides the kmsKeyName and environment options.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String getIamPolicy(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::GetPolicyOptions options)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::GetPolicyOptions options that provides requestedPolicyVersion option.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void getIamPolicy(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::GetPolicyOptions options, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::GetPolicyOptions options that provides requestedPolicyVersion option.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void getIamPolicy(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::GetPolicyOptions options, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::GetPolicyOptions options that provides requestedPolicyVersion option.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String setIamPolicy(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::SetPolicyOptions options)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::SetPolicyOptions options that provides Policy and updateMask settings.
Returns:
String
- The response payload.
Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void setIamPolicy(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::SetPolicyOptions options, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::SetPolicyOptions options that provides Policy and updateMask settings.aResult
- The async result (AsyncResult).
Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location.
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void setIamPolicy(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::SetPolicyOptions options, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.options
- The GoogleCloudFunctions::SetPolicyOptions options that provides Policy and updateMask settings.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location. For the list of permissions, see https://cloud.google.com/functions/docs/reference/iam/permissions
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
String testIamPermissions(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Permissions permissions)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.permissions
- The GoogleCloudFunctions::Permissions object that holds the list of permission string.
Returns:
String
- The response payload.
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location. For the list of permissions, see https://cloud.google.com/functions/docs/reference/iam/permissions
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void testIamPermissions(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Permissions permissions, AsyncResult &aResult)
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.permissions
- The GoogleCloudFunctions::Permissions object that holds the list of permission string.aResult
- The async result (AsyncResult).
The Firebase project Id should be only the name without the firebaseio.com. The location name is the project location. For the list of permissions, see https://cloud.google.com/functions/docs/reference/iam/permissions
@note Use FirebaseData.payload() to get the returned payload.
This function requires OAuth2.0 authentication.
void testIamPermissions(AsyncClientClass &aClient, const GoogleCloudFunctions::Parent &parent, const String &functionId, GoogleCloudFunctions::Permissions permissions, AsyncResultCallback cb, const String &uid = "")
Params:
aClient
- The async client.parent
- The GoogleCloudFunctions::Parent object included project Id and location name in its constructor.functionId
- The name of function.permissions
- The GoogleCloudFunctions::Permissions object that holds the list of permission string.cb
- The async result callback (AsyncResultCallback).uid
- The user specified UID of async result (optional).