It’s easy to access many of the Google Cloud Platform APIs from Cloud Functions by using a service account to act on your behalf. The service account provides Application Default Credentials for your functions so that you do not need to configure each one to use your personal user credentials.
Currently, Cloud Functions can write/read from the following services:
Supported Event Providers
Currently, Cloud Functions can be triggered by events provided by the following services:
HTTP—invoke functions directly via HTTP requests
Using Services with Cloud Functions
API client libraries that use application default credentials automatically obtain the built-in service account credentials from the Cloud Functions host at runtime. By default, the client authenticates using the service account file specified by the
GOOGLE_APPLICATION_CREDENTIALS environment variable, and uses the project specified by the
GCLOUD_PROJECT environment variable. These environment variables are set automatically on Google Cloud Functions.