> For the complete documentation index, see [llms.txt](https://docs.duplocloud.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.duplocloud.com/docs/getting-started/integrating-providers/google-cloud-platform-gcp.md).

# Google Cloud Platform (GCP)

The GCP Cloud Provider lets DuploCloud AI agents interact with your Google Cloud account — querying resources, running `gcloud` commands, and managing infrastructure on your behalf. Authentication uses a **Service Account** key.

***

## Step 1 — Create a Service Account Key in GCP

Before setting up the provider in DuploCloud, you need to generate a JSON key file from your GCP service account.

1. In the GCP Console, go to **IAM & Admin** → **Service Accounts**
2. Select an existing service account or create a new one
3. Click the service account → **Keys** tab → **Add Key** → **Create new key** → **JSON**
4. Click **Create** — GCP will download a JSON file to your machine

Open the downloaded JSON file. You will use three values from it when setting up DuploCloud:

* **`project_id`** — your GCP Project ID
* **`client_email`** — the service account email
* **`private_key`** — the full private key starting from `-----BEGIN RSA PRIVATE KEY-----`

> **Note:** The service account needs appropriate IAM roles assigned at the project level (e.g. **Viewer** for read-only access, or broader roles if the agent needs to create or modify resources).

***

## Step 2 — Add the GCP Provider

In DuploCloud, go to **Providers** in the left sidebar, select your tenant (e.g. **IT**), and click the **Cloud** tab. Click **+ Add**.

![Cloud providers list](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-27bc6ea962770c2395dbb59d063cc7d05d9ff4df%2Fgcp-step-01.png?alt=media)

Fill in the **Add Provider** form:

* **Name** — a name for this provider (e.g. `GCP-TEST`)
* **Type** — select `GCP`
* **Project ID** — your GCP project ID (found as `project_id` in the JSON key file)

Click **Create Provider**.

![Add Provider form](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-63a0ccabc5fc219a2a16ef0516a9e96b720d815c%2Fgcp-step-02.png?alt=media)

***

## Step 3 — Add a Credential

Click on your new provider to open it, then go to the **Credentials** tab and click **+ Add**.

The **Add Credential** form has two dedicated fields for GCP:

![Add Credential modal — empty](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-c1d03ac0f794fe2402927c8e0ff8b25956109c0a%2Fgcp-step-03.png?alt=media)

Fill in:

* **Name** — a name for this credential (e.g. `GCP-Test`)
* **Service Account Email** — the `client_email` value from the JSON key file
* **Service Account Password** — paste the full `private_key` value from the JSON key file, starting from `-----BEGIN RSA PRIVATE KEY-----` and including the closing `-----END RSA PRIVATE KEY-----` line

Click **Create**.

![Add Credential modal — filled](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-965089cc0fa7cdf491920c73c70f4cc7c8c9336e%2Fgcp-step-04.png?alt=media)

***

## Step 4 — Add a Scope

On the **Scope** tab, click **+ Add**.

* **Name** — a name for this scope (e.g. `GCP-test-scope`)
* **Credential** — select the credential you just created

Click **Create**. The scope appears in the list.

![Scope created](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-c0d38045041da06720b986909bbb56d7547549da%2Fgcp-step-05.png?alt=media)

***

## Step 5 — Use the Scope in a Ticket

Go to **HelpDesk** and create a new ticket. In the scope selector, choose the GCP scope from the dropdown.

![Scope dropdown with GCP scope selected](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-4e62738f284a9fe44690fcd540e35c4d3541a7f0%2Fgcp-step-06.png?alt=media)

Type your request and click **Create Ticket**.

![Ticket ready with GCP scope](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-7b9084aaae8deabf4e37449a52dd5a8138e9a014%2Fgcp-step-07.png?alt=media)

***

## Step 6 — Output

The agent authenticates with GCP using the service account and executes the request. Results appear in the ticket thread.

![Agent output — GCP query results](https://2471407984-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F68cb0s9ce5UIUKWPuYs8%2Fuploads%2Fgit-blob-4aff15ffa9193e9c245c36df6275468843293e82%2Fgcp-step-08.png?alt=media)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.duplocloud.com/docs/getting-started/integrating-providers/google-cloud-platform-gcp.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
