Generate Access Token
iam_credentials.generate_access_token
ActionGoogle Cloudconnection required
Calls IAM Service Account Credentials POST /v1/projects/{projectsId}/serviceAccounts/{serviceAccountsId}:generateAccessToken.
Generates an OAuth 2.0 access token for a service account.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- OAuth 2.0
- Providers
- Google IAM Service Account Credentials
- Secret shape
- {"client_id", "client_secret", "refresh_token"}
- Config it needs
- location, project_id
- Resolved by
- config.connection_id, else node.connection_id
Configuration
3 fields, 1 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
project_id GCP project id (overrides connection). | string | No | — | — | — |
service_account Service account id. | string | Yes | — | — | — |
body Request body (GenerateAccessTokenRequest) as JSON. | object | No | — | — | — |
Output
One shape.
result
| Field | Type | Example |
|---|---|---|
ok | boolean | — |
expireTime | string | — |
accessToken | string | — |
{
"accessToken": "",
"expireTime": "",
"ok": false
}Related Google IAM Service Account Credentials nodes
See Generate Access Token run in a workflow.
In a technical demo we add the Google IAM Service Account Credentials connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.