Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

fix(docs): clarify GCP service account key rotation steps and IAM API requirement

DimitrisStaratzis369df345fb96
diff --git a/docs/documentation/platform/secret-rotation/gcp-service-account-key.mdx b/docs/documentation/platform/secret-rotation/gcp-service-account-key.mdx
index fcaaa3d220..9f6fdd048b 100644
--- a/docs/documentation/platform/secret-rotation/gcp-service-account-key.mdx
+++ b/docs/documentation/platform/secret-rotation/gcp-service-account-key.mdx
@@ -3,7 +3,7 @@ title: "GCP service account key"
description: "Learn how to automatically rotate GCP service account keys."
---
-Rotate the JSON keys of a Google Cloud service account on a schedule. On each rotation, Infisical creates a new key for the service account, stores the key file in a secret, and deletes the key it created one rotation earlier.
+Rotate the JSON keys of a Google Cloud service account on a schedule. On each rotation, Infisical creates a new key for the service account, stores the key file in a secret, and deletes the key it created two rotation cycles earlier.
<Info>
**Rotation Type: Dual-Phase**
@@ -24,12 +24,19 @@ Rotate the JSON keys of a Google Cloud service account on a schedule. On each ro
## Step 1: Configure the service account for Infisical
-Infisical needs a GCP connection whose service account has the **Service Account Key Admin** role on the service account you want to rotate. The role lets Infisical create and delete keys for the service account you want to rotate.
+Infisical needs a GCP connection whose service account has the **Service Account Key Admin** role on the service account you want to rotate. The role lets Infisical create and delete keys for the service account you want to rotate. Infisical manages the keys through the Identity and Access Management (IAM) API, so that API must be enabled on the project that contains the connection's service account.
<Steps>
<Step>
If you don't have a GCP connection yet, create the connection's service account and let Infisical impersonate it, as described in [Configure service account for Infisical](/integrations/app-connections/gcp#configure-service-account-for-infisical).
</Step>
+ <Step>
+ Enable the IAM API (`iam.googleapis.com`) on the project that contains the connection's service account. This is a different API from the IAM Service Account Credentials API that the connection setup enables. You can enable it from the Google Cloud console or with the command line, replacing `projectId` with your GCP project ID:
+
+ ```bash
+ gcloud services enable iam.googleapis.com --project=projectId
+ ```
+ </Step>
<Step>
In the Google Cloud console, go to **IAM & Admin** > **Service Accounts** and select the service account you want to rotate.
</Step>