# googleapis/google-cloud-go architecture

> Architecture diagram of the GitHub repository googleapis/google-cloud-go, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/googleapis/google-cloud-go
- Repository: https://github.com/googleapis/google-cloud-go

## Overview

Google Cloud Client Libraries for Go is a collection of Go packages that let applications authenticate to and call Google Cloud service APIs. The principal workflow is an application creating a service client, supplying or detecting credentials, making an API request, and receiving a service response; the Storage package also provides a higher-level object API over its internal client. The graph highlights the source-index core modules and representative product branches. Many service clients were not sampled, so their service-call links rely on the README’s general description rather than inspected implementation details.

Main entry points: [`storage/storage.go`](https://github.com/googleapis/google-cloud-go/blob/main/storage/storage.go) (Storage API), [`storage/internal/apiv2/storage_client.go`](https://github.com/googleapis/google-cloud-go/blob/main/storage/internal/apiv2/storage_client.go) (Storage Client), [`storage/control/apiv2/storage_control_client.go`](https://github.com/googleapis/google-cloud-go/blob/main/storage/control/apiv2/storage_control_client.go) (Storage Control), [`storagebatchoperations/apiv1/storage_batch_operations_client.go`](https://github.com/googleapis/google-cloud-go/blob/main/storagebatchoperations/apiv1/storage_batch_operations_client.go) (Batch Operations)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_storage["Cloud Storage"]
  node_storage_sdk["Storage API<br/>[storage.go]"]
  node_storage_transport["Storage Client<br/>[storage_client.go]"]
  node_storage_control["Storage Control"]
  node_storage_batch["Batch Operations"]
  node_storage_insights["Storage Insights"]
  node_storage_transfer["Storage Transfer"]
end

subgraph group_ai_search["AI And Search"]
  node_rag_data["RAG Data"]
  node_genai_retrieval_alpha["GenAI Retrieval Alpha"]
  node_genai_retrieval_beta["GenAI Retrieval Beta"]
  node_site_search["Site Search"]
  node_site_search_alpha["Site Search Alpha"]
  node_site_search_beta["Site Search Beta"]
  node_sample_query_alpha["Sample Queries Alpha"]
  node_sample_query_beta["Sample Queries Beta"]
  node_pipeline["ML Pipelines<br/>[pipeline_client.go]"]
end

subgraph group_cloud_services["Cloud Services"]
  node_certificate_manager["Certificate Manager"]
  node_secure_source["Secure Source Manager"]
  node_bigquery_write["BigQuery Write"]
  node_bigquery_storage["BigQuery Storage"]
  node_bigquery_read["BigQuery Read"]
  node_bigquery_write_legacy["BigQuery Write Legacy"]
  node_monitoring_query["Monitoring Query<br/>[query_client.go]"]
  node_chronicle_export["Chronicle Export"]
  node_audience_ingestion["Audience Ingestion"]
end

subgraph group_shared["Client Foundations"]
  node_authentication["Authentication<br/>[auth.go]"]
end

node_application(("Go Application"))
node_cloud_api{{"Google Cloud APIs"}}

node_application -->|"creates client"| node_storage_sdk
node_storage_sdk -->|"calls"| node_storage_transport
node_application -->|"configures credentials"| node_authentication
node_storage_sdk -->|"calls"| node_cloud_api
node_storage_transport -->|"calls"| node_cloud_api
node_storage_control -->|"calls"| node_cloud_api
node_storage_batch -->|"calls"| node_cloud_api
node_storage_insights -->|"calls"| node_cloud_api
node_storage_transfer -->|"calls"| node_cloud_api
node_rag_data -->|"calls"| node_cloud_api
node_genai_retrieval_alpha -->|"calls"| node_cloud_api
node_genai_retrieval_beta -->|"calls"| node_cloud_api
node_site_search -->|"calls"| node_cloud_api
node_site_search_alpha -->|"calls"| node_cloud_api
node_site_search_beta -->|"calls"| node_cloud_api
node_sample_query_alpha -->|"calls"| node_cloud_api
node_sample_query_beta -->|"calls"| node_cloud_api
node_pipeline -->|"calls"| node_cloud_api
node_certificate_manager -->|"calls"| node_cloud_api
node_secure_source -->|"calls"| node_cloud_api
node_bigquery_write -->|"calls"| node_cloud_api
node_bigquery_storage -->|"calls"| node_cloud_api
node_bigquery_read -->|"calls"| node_cloud_api
node_bigquery_write_legacy -->|"calls"| node_cloud_api
node_monitoring_query -->|"calls"| node_cloud_api
node_chronicle_export -->|"calls"| node_cloud_api
node_audience_ingestion -->|"calls"| node_cloud_api

click node_storage_sdk "https://github.com/googleapis/google-cloud-go/blob/main/storage/storage.go"
click node_storage_transport "https://github.com/googleapis/google-cloud-go/blob/main/storage/internal/apiv2/storage_client.go"
click node_storage_control "https://github.com/googleapis/google-cloud-go/blob/main/storage/control/apiv2/storage_control_client.go"
click node_storage_batch "https://github.com/googleapis/google-cloud-go/blob/main/storagebatchoperations/apiv1/storage_batch_operations_client.go"
click node_storage_insights "https://github.com/googleapis/google-cloud-go/blob/main/storageinsights/apiv1/storage_insights_client.go"
click node_storage_transfer "https://github.com/googleapis/google-cloud-go/blob/main/storagetransfer/apiv1/storage_transfer_client.go"
click node_rag_data "https://github.com/googleapis/google-cloud-go/blob/main/aiplatform/apiv1beta1/vertex_rag_data_client.go"
click node_genai_retrieval_alpha "https://github.com/googleapis/google-cloud-go/blob/main/ai/generativelanguage/apiv1alpha/retriever_client.go"
click node_genai_retrieval_beta "https://github.com/googleapis/google-cloud-go/blob/main/ai/generativelanguage/apiv1beta/retriever_client.go"
click node_site_search "https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1/site_search_engine_client.go"
click node_site_search_alpha "https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1alpha/site_search_engine_client.go"
click node_site_search_beta "https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1beta/site_search_engine_client.go"
click node_sample_query_alpha "https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1alpha/sample_query_client.go"
click node_sample_query_beta "https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1beta/sample_query_client.go"
click node_pipeline "https://github.com/googleapis/google-cloud-go/blob/main/aiplatform/apiv1/pipeline_client.go"
click node_certificate_manager "https://github.com/googleapis/google-cloud-go/blob/main/certificatemanager/apiv1/certificate_manager_client.go"
click node_secure_source "https://github.com/googleapis/google-cloud-go/blob/main/securesourcemanager/apiv1/secure_source_manager_client.go"
click node_bigquery_write "https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1/big_query_write_client.go"
click node_bigquery_storage "https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1beta1/big_query_storage_client.go"
click node_bigquery_read "https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1beta2/big_query_read_client.go"
click node_bigquery_write_legacy "https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1beta2/big_query_write_client.go"
click node_monitoring_query "https://github.com/googleapis/google-cloud-go/blob/main/monitoring/apiv3/v2/query_client.go"
click node_chronicle_export "https://github.com/googleapis/google-cloud-go/blob/main/chronicle/apiv1/big_query_export_client.go"
click node_audience_ingestion "https://github.com/googleapis/google-cloud-go/blob/main/datamanager/apiv1/ingestion_client.go"
click node_authentication "https://github.com/googleapis/google-cloud-go/blob/main/auth/auth.go"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_storage_sdk,node_storage_transport,node_storage_control,node_storage_batch,node_storage_insights,node_storage_transfer toneBlue
class node_rag_data,node_genai_retrieval_alpha,node_genai_retrieval_beta,node_site_search,node_site_search_alpha,node_site_search_beta,node_sample_query_alpha,node_sample_query_beta,node_pipeline toneAmber
class node_certificate_manager,node_secure_source,node_bigquery_write,node_bigquery_storage,node_bigquery_read,node_bigquery_write_legacy,node_monitoring_query,node_chronicle_export,node_audience_ingestion,node_cloud_api toneMint
class node_authentication toneRose
class node_application toneIndigo
```

## Components

### Cloud Storage

- [Storage API](https://github.com/googleapis/google-cloud-go/blob/main/storage/storage.go): `storage/storage.go`
- [Storage Client](https://github.com/googleapis/google-cloud-go/blob/main/storage/internal/apiv2/storage_client.go): `storage/internal/apiv2/storage_client.go`
- [Storage Control](https://github.com/googleapis/google-cloud-go/blob/main/storage/control/apiv2/storage_control_client.go): `storage/control/apiv2/storage_control_client.go`
- [Batch Operations](https://github.com/googleapis/google-cloud-go/blob/main/storagebatchoperations/apiv1/storage_batch_operations_client.go): `storagebatchoperations/apiv1/storage_batch_operations_client.go`
- [Storage Insights](https://github.com/googleapis/google-cloud-go/blob/main/storageinsights/apiv1/storage_insights_client.go): `storageinsights/apiv1/storage_insights_client.go`
- [Storage Transfer](https://github.com/googleapis/google-cloud-go/blob/main/storagetransfer/apiv1/storage_transfer_client.go): `storagetransfer/apiv1/storage_transfer_client.go`

### AI And Search

- [RAG Data](https://github.com/googleapis/google-cloud-go/blob/main/aiplatform/apiv1beta1/vertex_rag_data_client.go): `aiplatform/apiv1beta1/vertex_rag_data_client.go`
- [GenAI Retrieval Alpha](https://github.com/googleapis/google-cloud-go/blob/main/ai/generativelanguage/apiv1alpha/retriever_client.go): `ai/generativelanguage/apiv1alpha/retriever_client.go`
- [GenAI Retrieval Beta](https://github.com/googleapis/google-cloud-go/blob/main/ai/generativelanguage/apiv1beta/retriever_client.go): `ai/generativelanguage/apiv1beta/retriever_client.go`
- [Site Search](https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1/site_search_engine_client.go): `discoveryengine/apiv1/site_search_engine_client.go`
- [Site Search Alpha](https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1alpha/site_search_engine_client.go): `discoveryengine/apiv1alpha/site_search_engine_client.go`
- [Site Search Beta](https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1beta/site_search_engine_client.go): `discoveryengine/apiv1beta/site_search_engine_client.go`
- [Sample Queries Alpha](https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1alpha/sample_query_client.go): `discoveryengine/apiv1alpha/sample_query_client.go`
- [Sample Queries Beta](https://github.com/googleapis/google-cloud-go/blob/main/discoveryengine/apiv1beta/sample_query_client.go): `discoveryengine/apiv1beta/sample_query_client.go`
- [ML Pipelines](https://github.com/googleapis/google-cloud-go/blob/main/aiplatform/apiv1/pipeline_client.go): `aiplatform/apiv1/pipeline_client.go`

### Cloud Services

- [Certificate Manager](https://github.com/googleapis/google-cloud-go/blob/main/certificatemanager/apiv1/certificate_manager_client.go): `certificatemanager/apiv1/certificate_manager_client.go`
- [Secure Source Manager](https://github.com/googleapis/google-cloud-go/blob/main/securesourcemanager/apiv1/secure_source_manager_client.go): `securesourcemanager/apiv1/secure_source_manager_client.go`
- [BigQuery Write](https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1/big_query_write_client.go): `bigquery/storage/apiv1/big_query_write_client.go`
- [BigQuery Storage](https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1beta1/big_query_storage_client.go): `bigquery/storage/apiv1beta1/big_query_storage_client.go`
- [BigQuery Read](https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1beta2/big_query_read_client.go): `bigquery/storage/apiv1beta2/big_query_read_client.go`
- [BigQuery Write Legacy](https://github.com/googleapis/google-cloud-go/blob/main/bigquery/storage/apiv1beta2/big_query_write_client.go): `bigquery/storage/apiv1beta2/big_query_write_client.go`
- [Monitoring Query](https://github.com/googleapis/google-cloud-go/blob/main/monitoring/apiv3/v2/query_client.go): `monitoring/apiv3/v2/query_client.go`
- [Chronicle Export](https://github.com/googleapis/google-cloud-go/blob/main/chronicle/apiv1/big_query_export_client.go): `chronicle/apiv1/big_query_export_client.go`
- [Audience Ingestion](https://github.com/googleapis/google-cloud-go/blob/main/datamanager/apiv1/ingestion_client.go): `datamanager/apiv1/ingestion_client.go`

### Client Foundations

- [Authentication](https://github.com/googleapis/google-cloud-go/blob/main/auth/auth.go): `auth/auth.go`

### Other components

- **Go Application**
- **Google Cloud APIs**

## Connections

- Go Application → Storage API: creates client (evidence: `README.md`)
- Storage API → Storage Client: calls (evidence: `storage/storage.go`)
- Go Application → Authentication: configures credentials (evidence: `README.md`)
- Storage API → Google Cloud APIs: calls (evidence: `README.md`)
- Storage Client → Google Cloud APIs: calls (evidence: `README.md`)
- Storage Control → Google Cloud APIs: calls (evidence: `README.md`)
- Batch Operations → Google Cloud APIs: calls (evidence: `README.md`)
- Storage Insights → Google Cloud APIs: calls (evidence: `README.md`)
- Storage Transfer → Google Cloud APIs: calls (evidence: `README.md`)
- RAG Data → Google Cloud APIs: calls (evidence: `README.md`)
- GenAI Retrieval Alpha → Google Cloud APIs: calls (evidence: `README.md`)
- GenAI Retrieval Beta → Google Cloud APIs: calls (evidence: `README.md`)
- Site Search → Google Cloud APIs: calls (evidence: `README.md`)
- Site Search Alpha → Google Cloud APIs: calls (evidence: `README.md`)
- Site Search Beta → Google Cloud APIs: calls (evidence: `README.md`)
- Sample Queries Alpha → Google Cloud APIs: calls (evidence: `README.md`)
- Sample Queries Beta → Google Cloud APIs: calls (evidence: `README.md`)
- ML Pipelines → Google Cloud APIs: calls (evidence: `README.md`)
- Certificate Manager → Google Cloud APIs: calls (evidence: `README.md`)
- Secure Source Manager → Google Cloud APIs: calls (evidence: `README.md`)
- BigQuery Write → Google Cloud APIs: calls (evidence: `README.md`)
- BigQuery Storage → Google Cloud APIs: calls (evidence: `README.md`)
- BigQuery Read → Google Cloud APIs: calls (evidence: `README.md`)
- BigQuery Write Legacy → Google Cloud APIs: calls (evidence: `README.md`)
- Monitoring Query → Google Cloud APIs: calls (evidence: `README.md`)
- Chronicle Export → Google Cloud APIs: calls (evidence: `README.md`)
- Audience Ingestion → Google Cloud APIs: calls (evidence: `README.md`)
