Workflows publishes connectors that make it easier to access other
Google Cloud products within a workflow. This document details the correct
Workflows syntax for the available connectors.

For workflow samples that demonstrate how to use a connector, see each
connector's overview page.

To learn more about authentication, and behavior during retries and long-running
operations, see [Understand connectors](https://docs.cloud.google.com/workflows/docs/connectors.md.txt).

## Invoke a connector call

Similar to [invoking an HTTP endpoint](https://docs.cloud.google.com/workflows/docs/http-requests.md.txt),
a connector call requires `call` and `args` fields. You can specify a timeout
value and polling policy using the `connector_params` block:

```yaml
- STEP_NAME:
    call: CONNECTOR
    args:
        ARG: ARG_VALUE
        [...]
        body:
            KEY:KEY_VALUE
            [...]
        connector_params:
            timeout: TIMEOUT_IN_SECONDS
            polling_policy:
                initial_delay: INITIAL_DELAY_IN_SECONDS
                multiplier: MULTIPLIER_VALUE
                max_delay: MAX_DELAY_IN_SECONDS
            skip_polling: SKIP_POLLING_SWITCH 
            scopes:  OAUTH2_SCOPE 
    result: RESPONSE_VALUE
```

Replace the following:

- `STEP_NAME`: the name of the step.
- `CONNECTOR` (required): the connector method in the form `googleapis.gcp_service.version.resource.operation`. For example, `googleapis.bigquery.v2.tables.get`.
- `ARG` and `ARG_VALUE` (required): each connector call requires different arguments.
- `KEY` and `KEY_VALUE` (optional): fields to supply input to the API.
- Connector-specific parameters (optional):
  - `TIMEOUT_IN_SECONDS`: time in seconds. The end-to-end duration the connector call is allowed to run for before throwing a timeout exception. The default value is `1800` and this should be the maximum for connector methods that are not long-running operations. Otherwise, for long-running operations, the maximum timeout for a connector call is `31536000` seconds (one year).
  - `INITIAL_DELAY_IN_SECONDS`: polling policy parameter with a default value of `1.0`. Only applies to long-running operation calls.
  - `MULTIPLIER_VALUE`: polling policy parameter with a default value of `1.25`. Only applies to long-running operation calls.
  - `MAX_DELAY_IN_SECONDS`: polling policy parameter with a default value of `60.0`. Only applies to long-running operation calls.
  - `SKIP_POLLING_SWITCH`: if set to `True`, the connector invocation call is non-blocking if the initial request to manage or update the resource succeeds (usually `HTTP POST`, `HTTP UPDATE`, or `HTTP DELETE`). If the initial request is not successful, retries might occur. Polling of status (`HTTP GET` requests that follow the initial request) is skipped for the long-running operation after the initial request completes. The default value is `False`.
  - `OAUTH2_SCOPE`: OAuth2 scopes to pass to the Google API. Can be a string, list of strings, space-separated string, or comma-separated string.
- `RESPONSE_VALUE` (optional): variable name where the result of a connector call invocation step is stored.

## List of supported connectors

| Google Cloud product | Connector | Long-running operation type |
|---|---|---|
| [AI Platform Training](https://docs.cloud.google.com/ai-platform/training/docs) | [ml](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/ml/Overview) | [Job](https://docs.cloud.google.com/ai-platform/training/docs/reference/rest/v1/projects.jobs#Job) |
| [Application Integration](https://docs.cloud.google.com/application-integration/docs.md.txt) | [integrations](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/integrations/Overview) | None |
| [Batch](https://docs.cloud.google.com/batch/docs.md.txt) | [batch](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/batch/Overview) | [Job](https://docs.cloud.google.com/batch/docs/reference/rest/v1/projects.locations.jobs.md.txt#Job) [Operation](https://docs.cloud.google.com/batch/docs/reference/rest/Shared.Types/ListOperationsResponse.md.txt#Operation) |
| [BigQuery](https://docs.cloud.google.com/bigquery/docs.md.txt) | [bigquery](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/bigquery/Overview) | [Job](https://docs.cloud.google.com/bigquery/docs/reference/rest/v2/Job.md.txt) |
| [BigQuery Data Transfer Service](https://docs.cloud.google.com/bigquery/docs/dts-introduction.md.txt) | [bigquerydatatransfer](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/bigquerydatatransfer/Overview) | [TransferRun](https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/rest/v1/projects.locations.transferConfigs.runs.md.txt) |
| [Cloud Build](https://docs.cloud.google.com/build/docs.md.txt) | [cloudbuild](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/cloudbuild/Overview) | [Operation](https://docs.cloud.google.com/build/docs/api/reference/rest/v1/operations.md.txt#Operation) |
| [Cloud Run functions](https://docs.cloud.google.com/functions/docs.md.txt) | [cloudfunctions](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/cloudfunctions/Overview) | [Operation](https://docs.cloud.google.com/functions/docs/reference/rest/v1/operations.md.txt#Operation) |
| [Cloud Natural Language API](https://docs.cloud.google.com/natural-language/docs.md.txt) | [language](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/language/Overview) | None |
| [Cloud Run](https://docs.cloud.google.com/run/docs.md.txt) | [run](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/run/Overview) | None |
| [Cloud Scheduler](https://docs.cloud.google.com/scheduler/docs.md.txt) | [cloudscheduler](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/cloudscheduler/Overview) | None |
| [Cloud SQL](https://docs.cloud.google.com/sql/docs.md.txt) | [sqladmin](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/sqladmin/Overview) | [Operation](https://docs.cloud.google.com/sql/docs/mysql/admin-api/rest/v1beta4/operations.md.txt#Operation) |
| [Cloud Storage](https://docs.cloud.google.com/storage/docs.md.txt) | [storage](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/storage/Overview) | None |
| [Cloud Tasks](https://docs.cloud.google.com/tasks/docs.md.txt) | [cloudtasks](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/cloudtasks/Overview) | None |
| [Cloud Translation](https://docs.cloud.google.com/translate/docs.md.txt) | [translate](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/translate/Overview) | [Operation](https://docs.cloud.google.com/translate/docs/reference/rest/v3/projects.locations.operations.md.txt) |
| [Compute Engine](https://docs.cloud.google.com/compute/docs.md.txt) | [compute](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/compute/Overview) | [Operation](https://docs.cloud.google.com/compute/docs/reference/rest/v1/globalOperations.md.txt#resource:-operation) |
| [Dataflow](https://docs.cloud.google.com/dataflow/docs.md.txt) | [dataflow](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/dataflow/Overview) | [Job](https://docs.cloud.google.com/dataflow/docs/reference/rest/v1b3/projects.locations.jobs.md.txt#resource:-job) |
| [Document AI](https://docs.cloud.google.com/document-ai/docs.md.txt) | [documentai](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/documentai/Overview) | [Operation](https://docs.cloud.google.com/document-ai/docs/reference/rest/v1/projects.locations.operations.md.txt#Operation) [Processor](https://docs.cloud.google.com/document-ai/docs/reference/rest/v1/projects.locations.processors.md.txt#Processor) |
| [Firestore](https://docs.cloud.google.com/firestore/docs) | [firestore](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/firestore/Overview) | [Operation](https://docs.cloud.google.com/firestore/docs/reference/rest/Shared.Types/Operation.md.txt) |
| [Google Forms](https://developers.google.com/forms/api/guides) | [forms](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/forms/Overview) | None |
| [Google Kubernetes Engine](https://docs.cloud.google.com/kubernetes-engine/docs.md.txt) | [container](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/container/Overview) | [Operation](https://docs.cloud.google.com/kubernetes-engine/docs/reference/rest/v1/projects.locations.operations.md.txt#resource:-operation) |
| [Google Sheets](https://developers.google.com/sheets/api/guides/concepts) | [sheets](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/sheets/Overview) | None |
| [Kubernetes API (control plane)](https://docs.cloud.google.com/workflows/docs/access-kubernetes-api.md.txt) | [gke](https://docs.cloud.google.com/workflows/docs/reference/connectors/gke/Overview.md.txt) | None |
| [Pub/Sub](https://docs.cloud.google.com/pubsub/docs.md.txt) | [pubsub](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/pubsub/Overview) | None |
| [Resource Manager](https://docs.cloud.google.com/resource-manager/docs.md.txt) | [cloudresourcemanager](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/cloudresourcemanager/Overview) | None |
| [Secret Manager](https://docs.cloud.google.com/secret-manager/docs.md.txt) | [secretmanager](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/secretmanager/Overview) | None |
| [Spanner](https://docs.cloud.google.com/spanner/docs.md.txt) | [spanner](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/spanner/Overview) | [Operation](https://docs.cloud.google.com/spanner/docs/reference/rest/v1/projects.instances.backups.operations.md.txt#Operation) |
| [Storage Transfer Service](https://docs.cloud.google.com/storage-transfer/docs) | [storagetransfer](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/storagetransfer/Overview) | [Operation](https://docs.cloud.google.com/storage-transfer/docs/reference/rest/v1/Operation.md.txt) |
| [Transcoder API](https://docs.cloud.google.com/transcoder/docs.md.txt) | [transcoder](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/transcoder/Overview) | [Job](https://docs.cloud.google.com/transcoder/docs/reference/rest/v1/projects.locations.jobs.md.txt#Job) |
| [Vertex AI](https://docs.cloud.google.com/vertex-ai/docs) | [aiplatform (Vertex AI)](https://docs.cloud.google.com/workflows/docs/reference/googleapis/aiplatform/Overview.md.txt) | [Artifact](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.metadataStores.artifacts#Artifact) [Execution](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.metadataStores.executions#Execution) [Job](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.batchPredictionJobs#BatchPredictionJob) [Operation](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/Shared.Types/ListOperationsResponse#Operation) [Pipeline](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.pipelineJobs#PipelineJob) [Schedule](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.schedules#Schedule) [Study](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.studies#Study) [Trial](https://docs.cloud.google.com/vertex-ai/docs/reference/rest/v1/projects.locations.studies.trials#Trial) |
| [Workflows](https://docs.cloud.google.com/workflows/docs.md.txt) | [workflows](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/workflows/Overview) [workflowexecutions](https://docs.cloud.google.com/workflows/docs/reference/stdlib/googleapis/workflowexecutions/Overview) | [Operation](https://docs.cloud.google.com/workflows/docs/reference/rest/v1/projects.locations.operations.md.txt) [Execution](https://docs.cloud.google.com/workflows/docs/reference/executions/rest/v1/projects.locations.workflows.executions.md.txt) |