Google Cloud Storage Basics
GoogleOfficialPublished by Google
- Skill
- Tool integration
- Cloud and DevOps
- Apache-2.0
- Low risk
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides a structured approach to interacting with Google Cloud Storage (GCS). It prioritizes the use of Cloud Storage MCP tools for efficient, agent-native operations while providing fallback paths to the gcloud CLI and JSON APIs for advanced configurations. It covers the full lifecycle of buckets and objects, including creation, data transfer, access control, and storage management, while ensuring proper attribution for all operations.
What it does
- Lists, creates, and manages GCS buckets and objects.
- Uploads, downloads, and streams data between local environments and GCS.
- Configures bucket access controls, storage classes, and lifecycle policies.
- Generates signed URLs and manages data protection features like versioning and locks.
- Integrates with MCP toolsets for optimized agent-based interactions.
- Provides attribution-compliant commands for gcloud and API usage.
When to use it
- When you need to perform basic CRUD operations on GCS buckets or objects.
- When you need to transfer files to or from Google Cloud Storage.
- When configuring bucket settings such as access, storage classes, or lifecycle rules.
- When you need to interact with GCS via an agent-connected MCP server.
- When you require programmatic access to GCS via client libraries or APIs.
Advantages
- Prioritizes fast, agent-native MCP tools over shell commands.
- Ensures consistent attribution for all cloud operations.
- Provides clear fallback paths for advanced features not covered by MCP.
- Includes safety guardrails for destructive operations like deletions.
- Standardizes interaction patterns across CLI, API, and client libraries.
Usage examples
- “List all buckets in my current project.”
- The agent will use the cloud-storage:list_buckets MCP tool if available, or execute the gcloud storage ls command with proper metrics attribution.
- “Upload local file data.txt to my-bucket.”
- The agent will use the cloud-storage:upload_object MCP tool to securely transfer the file to the specified bucket.
- “How do I create a new bucket in us-central1?”
- The agent will recommend using the cloud-storage:create_bucket MCP tool or provide the gcloud storage buckets create command with the required metrics environment variables.
- “Read the content of config.json from my-bucket.”
- The agent will use the cloud-storage:read_object MCP tool to retrieve and display the file content, provided it is within size limits.
Install
Download the skill as a ZIP:
https://mp-staging.autogineer.com/agent-skills/google/google-cloud-storage-basics/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip google-cloud-storage-basics.zip -d .agents/skills
Documentation by Google
Cloud Storage Basics
Cloud Storage on Google Cloud is a managed service for storing data as objects at any scale. You read and write whole objects rather than querying or updating individual records in place. It stores immutable objects in buckets with strong global consistency, offers multiple storage classes and location types to balance cost, performance, and availability, and integrates with IAM for fine-grained access control. Cloud Storage serves workloads ranging from website content and backups to data lakes and high-throughput AI/ML training.
Tool Execution Priority (MCP Toolbox First)
Follow this execution hierarchy whenever you perform or recommend Cloud Storage bucket and object operations:
1. Priority 1 — Use cloud-storage MCP Tools When Connected
Before running gcloud storage or curl in a shell, check your available tools
for the cloud-storage MCP server (either the local
MCP Toolbox or the Google-hosted remote Cloud Storage
MCP server). Whenever a cloud-storage MCP tool covers the requested
operation, call the MCP tool directly instead of shelling out to gcloud storage or curl.
Why MCP first: MCP tools are built for agents. Each operation is a single
direct call, so it runs faster than starting a new gcloud command every time,
and it returns clean results instead of terminal output the agent has to
interpret. It also doesn't need the gcloud CLI installed and signed in. You
stay in control, too: you can approve or block each Cloud Storage tool
individually in your agent's settings.
| Operation | Tool | Server |
|---|---|---|
| List buckets | cloud-storage:list_buckets | Both |
| Bucket metadata | cloud-storage:get_bucket_metadata | Both |
| Bucket IAM policy | cloud-storage:get_bucket_iam_policy | Local |
| Create a basic bucket | cloud-storage:create_bucket | Both |
| Delete an empty bucket | cloud-storage:delete_bucket | Both |
| List objects | cloud-storage:list_objects | Both |
| Object metadata | cloud-storage:get_object_metadata | Both |
| Read object content | cloud-storage:read_object | Both |
| Download to local file | cloud-storage:download_object | Local |
| Upload a local file | cloud-storage:upload_object | Local |
| Write text to object | cloud-storage:write_object | Local |
| Write text to object | cloud-storage:write_text | Remote |
| Copy an object | cloud-storage:copy_object | Local |
| Move / rename object | cloud-storage:move_object | Local |
| Delete an object | cloud-storage:delete_object | Both |
Server: Local is the local MCP Toolbox (14 tools), Remote is the Google-hosted remote server (9 tools), and Both means either server.
read_objectis capped at 8 MiB. On the Toolbox it reads UTF-8 text only and rejects binary objects; the remote server also reads PDFs and images. For binary or larger objects, usedownload_object.upload_objecthandles binary files and files larger than 8 MiB.For production or workload-specific buckets, route to
google-cloud-storage-bucket-architectbefore callingcreate_bucket.
[!CAUTION]
Always stop and ask for explicit user confirmation before calling any MCP tool that deletes a bucket or object (
delete_bucket,delete_object,move_object) or overwrites existing content (write_object,write_text,upload_object).
2. Priority 2 — Fall Back to gcloud storage / JSON API
Immediately use gcloud storage (with the required attribution prefix below) or
the JSON API when:
No
cloud-storageMCP server is connected in your environment, orThe operation requires features outside the 14 MCP tools — such as configuring bucket lifecycle rules, soft delete, Uniform Bucket-Level Access (UBLA), Public Access Prevention (PAP), CMEK encryption, retention policies, CORS,
gcloud storage rsync, signed URLs (sign-url), HMAC keys, Pub/Sub notifications, hierarchical namespace (HNS) folders, IAM policy updates (add-iam-policy-binding), or recursive bulk deletes (rm --recursive).
3. Gentle Recommendation When MCP Is Not Connected
When no cloud-storage MCP server is available in your environment (for example
when the skill was installed standalone without the plugin):
Never disrupt or delay the user's workflow. Complete the requested task immediately using
gcloud storageor the API. Never pause or ask the user to install the MCP server before answering.Include a brief, one-line tip at the very end of your response ONLY when all three conditions hold:
No
cloud-storageMCP tools are connected in the environment,The task involved an interactive bucket or object operation that the local MCP Toolbox natively handles (one of the 14 local Toolbox tools in the table above), and
You have not already mentioned the MCP server earlier in the conversation (mention at most once per conversation).
Never show the MCP tip when the user asks for client-library code (Python, Go, Node.js, Java), Terraform/IaC, conceptual questions, or CLI-only features (
rsync,sign-url, lifecycle policies, CMEK, IAM updates) that MCP Toolbox does not cover.Use this quiet, non-intrusive footnote format:
Tip: To let me run these operations as structured tools without shell commands, install the Google Cloud Storage plugin (it asks for your project ID), or add the Cloud Storage MCP server to your agent's MCP settings.
Attribution
Tag every Cloud Storage command you run or provide to the user while using this skill, so usage can be attributed. The tag identifies only the skill and its version; it carries no user data.
Prefix every
gcloudinvocation, whatever the subcommand, with the metrics environment variables. Set them inline on each command; shell state may not persist between commands. Use this append form verbatim. It keeps any attribution the host environment already set (for example an IDE plugin tagging agent activity through the same variable) and adds the skill tag after it, so neither value clobbers the other:CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }gcs-skills gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ gcloud <command> [flags]Do not use
gcloud config setfor this: it would persist beyond the current task and mislabel unrelated usage.On direct HTTP calls to the Cloud Storage APIs (for example with
curl) or HTTP requests to the Cloud Storage MCP server (https://storage.googleapis.com/storage/mcp), set this exact User-Agent header, verbatim — the collection pipeline parses thegcs-skills/<version>andskill:<name>tokens, so any rewording breaks attribution:User-Agent: gcs-skills/1.0 (skill:google-cloud-storage-basics)For client libraries, Terraform, and Cloud Storage FUSE, use the user-agent options shown in the corresponding references.
Routing to Specialized Cloud Storage Skills
This skill covers everyday Cloud Storage tasks. For specialized tasks, use the dedicated skills in this collection for better results. Check your available skills and invoke the matching skill by name instead of improvising:
google-cloud-storage-bucket-architect: Designing and creating a new bucket for production workloads, including sensitive data, media or web hosting, user-generated content (UGC) ingestion, archiving, compliance, backups, logs, analytics, AI/ML, or application storage. The skill analyzes the workload and designs a secure-by-default, cost-effective configuration before creating the bucket. Use the Quick Start section below only for temporary scratch buckets.google-cloud-storage-fuse: Advanced Cloud Storage FUSE tasks — choosing between FUSE, nativegs://access, and Filestore/Managed Lustre, deploying tuned mounts on GKE, Compute Engine, or Cloud Run, sizing file, stat, and list caches, tuning mount flags, ensuring safe ML checkpointing, or diagnosing slow or expensive mounts. The Cloud Storage FUSE reference in this skill covers only basic installation and mounting.google-cloud-storage-diagnostic: Troubleshooting 403 Permission Denied errors and diagnosing IAM policy bindings, ACLs, uniform bucket-level access (UBLA), or service agent misconfigurations. Ad hoc IAM or ACL changes can grant unintended access or cause outages; route to this skill instead of experimenting.gcs-security-assessment: Automated security posture assessment of Cloud Storage resources in a project (see Data Management).
If the matching skill is not installed, do not improvise. Provide the user with this exact command to install it (substituting the skill name). Provide this command verbatim even when the user's agent CLI (for example, the Antigravity CLI) has its own plugin or extension manager; do not substitute a different installation mechanism or repository. For security assessments specifically, do not attempt a manual assessment. Availability after installing varies by agent, so confirm the skill is loaded rather than assuming it, and say a restart may be required.
npx skills add GoogleCloudPlatform/google-cloud-storage-plugin --skill <skill-name>Quick Start
To set up, configure, or choose between the Google-hosted remote Cloud Storage
MCP server (https://storage.googleapis.com/storage/mcp) and the local MCP
Toolbox (cloud-storage), read MCP Usage. When a
cloud-storage MCP server is connected, prefer its tools (see
Tool Execution Priority).
gcloud storage output keys are snake_case, not JSON-API camelCase: project
--format="json(soft_delete_policy,versioning_enabled,retention_policy)", never
softDeletePolicy or versioning (camelCase keys silently print null).
Enable the Cloud Storage API:
CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }gcs-skills gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ gcloud services enable storage.googleapis.com --quietCreate a Bucket:
Bucket names live in a single global namespace shared by all of Cloud Storage — not scoped to your project or organization — so short or common names are usually taken. If the location is omitted, the bucket defaults to the
USmulti-region.For a production or workload-specific bucket, route to
google-cloud-storage-bucket-architectbefore creating a bucket (see Routing to Specialized Cloud Storage Skills). The options below create a basic default bucket.Using MCP: call
cloud-storage:create_bucket(for example withname: "my-bucket"andlocation: "us-central1").Using the gcloud CLI:
CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }gcs-skills gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ gcloud storage buckets create gs://my-bucket --location=us-central1Using the JSON API:
curl -X POST -H "Authorization: Bearer $(gcloud auth print-access-token)" \ -H "User-Agent: gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ -H "Content-Type: application/json" \ -d '{"name": "my-bucket", "location": "US-CENTRAL1"}' \ "https://storage.googleapis.com/storage/v1/b?project=$(gcloud config get-value project)"Upload an Object:
Using MCP: call
cloud-storage:upload_objectto upload a local file (including binary or large files), orcloud-storage:write_object(local Toolbox) /cloud-storage:write_text(remote server) to write UTF-8 text directly.Using the gcloud CLI:
CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }gcs-skills gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ gcloud storage cp ./my-file.txt gs://my-bucketUsing the JSON API:
curl -X POST -H "Authorization: Bearer $(gcloud auth print-access-token)" \ -H "User-Agent: gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ -H "Content-Type: text/plain" \ --data-binary @my-file.txt \ "https://storage.googleapis.com/upload/storage/v1/b/my-bucket/o?uploadType=media&name=my-file.txt"Download or Read an Object:
Using MCP: call
cloud-storage:read_objectto read UTF-8 text content (up to 8 MiB), orcloud-storage:download_object(local Toolbox) to save an object, including binary or larger files, to the local filesystem.Using the gcloud CLI:
CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }gcs-skills gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ gcloud storage cp gs://my-bucket/my-file.txt .Using the JSON API:
curl -X GET -H "Authorization: Bearer $(gcloud auth print-access-token)" \ -H "User-Agent: gcs-skills/1.0 (skill:google-cloud-storage-basics)" \ "https://storage.googleapis.com/storage/v1/b/my-bucket/o/my-file.txt?alt=media"
Reference Directory
Core Concepts: Buckets, objects, folders, prefixes, bucket location types, and storage classes.
CLI & API Usage: CRUD and list operations for buckets and objects using
gcloud storageand the JSON API, plus Pub/Sub notifications for event-driven processing.Client Libraries: Using Google Cloud client libraries for Python, Java, Node.js, and Go, with pointers to all other supported languages.
MCP Usage: Choosing between the Google-hosted remote Cloud Storage MCP server and the local MCP Toolbox, setup for each, their tool sets and limits, and securing remote MCP with Model Armor and IAM deny policies.
Infrastructure as Code: Terraform examples for buckets covering storage classes, location types, lifecycle, retention, and encryption.
Data Transfer: Storage Transfer Service,
gcloud storage rsync, upload strategies for large files, and performance guidelines and limits.Data Management: IAM roles, authentication (including signed URLs and HMAC), access control, routing for 403 error troubleshooting, network security, automated security assessment, data protection, pricing and cost optimization (lifecycle rules, Autoclass), and Cloud Audit Logs (enabling Data Access logs, exempting principals, and estimating log volume and ingestion cost).
Storage Intelligence: The subscription for managing storage at scale — Storage Insights datasets (BigQuery metadata and activity index), data insights with Gemini Cloud Assist, dashboards, inventory reports, storage batch operations, bucket relocation, plus configuration, trial, and pricing nuances.
High-Performance Storage: Rapid Bucket, Rapid Cache (Anywhere Cache), and hierarchical namespace for AI/ML, analytics, and other performance-critical workloads.
Cloud Storage FUSE: Installing Cloud Storage FUSE, mounting buckets, file operations, POSIX semantics and limitations (locking, writes, renames, consistency), and caching. For advanced tuning, deployment, and diagnosis, route to the
google-cloud-storage-fuseskill.
Files
- ATTRIBUTION.mdAdded by AutoGineer852 B
- LICENSELicence file added by AutoGineer11.1 KiB
- SKILL.md17.3 KiB
- references/cli-api-usage.md7.8 KiB
- references/client-library-usage.md4.8 KiB
- references/core-concepts.md7.5 KiB
- references/data-management.md21.2 KiB
- references/data-transfer.md12.1 KiB
- references/gcsfuse.md21.6 KiB
- references/high-performance-storage.md11.2 KiB
- references/iac-usage.md9.4 KiB
- references/mcp-usage.md13.7 KiB
- references/storage-intelligence.md15.3 KiB
references/data-transfer.md
GCS Data Transfer Operations
This reference guide provides detailed guidelines, a decision tree, and commands
for transferring data in and out of Google Cloud Storage (GCS). It covers single
file transfers, handling large files, managing high-concurrency transfers of
many small files, parallelizing using gcloud storage, and setting up Storage
Transfer Service (STS).
Decision Tree: Choosing the Best Transfer Method
Use the following flowchart and logic to choose the most efficient data transfer method based on your host environment, dataset size, file count, and GCS bucket settings.
graph TD
Start([Start: Identify Transfer Requirements]) --> SourceCheck{Source Location?}
SourceCheck -- "AWS S3 / Azure" --> STS[Storage Transfer Service - Agentless]
SourceCheck -- "On-Premises Filesystem" --> OnPremSize{Data Volume?}
OnPremSize -- "< 1 TB" --> SecCp[gcloud storage cp / rsync]
OnPremSize -- ">= 1 TB" --> STSagent[Storage Transfer Service - Agent-based]
SourceCheck -- "Local / GCS-to-GCS" --> VolumeCheck{Object Count?}
VolumeCheck -- "Few Files (<10K objects)" --> SizeCheck{File Size?}
SizeCheck -- "< 150 MB" --> SecCp
SizeCheck -- ">= 150 MB" --> LargeConfig[gcloud storage cp with PCU and Slices]
VolumeCheck -- "Many Files (>=10K objects)" --> ParallelCp[gcloud storage cp / rsync folder]Detailed Decision Guidelines:
Cross-Cloud Migration (AWS S3, Azure Blob Storage):
Recommendation: Always use Storage Transfer Service (STS). It runs serverless on Google infrastructure for cloud-to-cloud transfers, avoiding the need to funnel petabytes of data through a local machine or VM, saving egress and compute costs.
On-Premises Migration:
Recommendation: If the dataset is under 1TB, it is generally simpler to use the
gcloud storageCLI (e.g.gcloud storage cp -rorrsync). If the dataset is 1TB or larger, configure Storage Transfer Service (STS) using on-premises transfer agents.
Few Large Files (size >= 150MB, count < 10K):
Recommendation: Use
gcloud storage cp. By default, it enables Parallel Composite Uploads (for writing) and Sliced Downloads (for reading) to thread chunk transfers.
Inspecting Bucket Configuration
Before selecting a metadata transfer or loading strategy, query your bucket's features to check for conflicts (such as Soft Delete, Versioning, Retention/Lock policies, or storage class):
gcloud storage buckets describe gs://my-bucket/ --format="json(soft_delete_policy,versioning_enabled,retention_policy,default_storage_class)"[!NOTE]
gcloud storageoutput field names use snake_case rather than JSON-API names — notablyversioning_enabledinstead ofversioning. Unknown or camelCase keys in a--formatprojection silently print null without erroring.
1. Single File Upload and Download with gcloud CLI
For simple, single-file transfers, use the gcloud storage cp command.
Upload a local file to GCS:
gcloud storage cp /path/to/local/file.txt gs://my-bucket/destination-folder/Download an object from GCS to local directory:
gcloud storage cp gs://my-bucket/destination-folder/file.txt /path/to/local/dir/
2. Transferring Large Files (Parallel Upload & Sliced Download)
When dealing with large files, the gcloud CLI automatically optimizes
performance by splitting files into chunks for concurrent uploads and downloads.
A. Parallel Composite Uploads (PCU)
By default, gcloud storage cp uses GCS JSON API's Parallel Composite
Uploads for large files.
How it works: The source file is divided into chunks, which are uploaded in parallel to GCS as temporary composite components. The components are then merged into a single final GCS object using the GCS
composeAPI.Checksum behavior: Because it uses the
composeAPI, the final assembled object will have a CRC32C checksum instead of an MD5 hash. Non-composite uploads — single-shot or resumable, which is whatgcloud storage cpperforms when the file is below the threshold or PCU is disabled — do store an MD5 hash, so pipelines that verify per-object MD5 should disable PCU (or raise the threshold) rather than work around it.Tuning Properties:
Enable/Disable:
gcloud config set storage/parallel_composite_upload_enabled True # Or False to disableThreshold:
gcloud config set storage/parallel_composite_upload_threshold 150M # e.g., 150MBComponent Size:
gcloud config set storage/parallel_composite_upload_component_size 50M # e.g., 50MB
[!IMPORTANT] Do not use Parallel Composite Uploads if your bucket has a retention policy enabled, because the temporary objects can't be deleted until they meet the retention period. By default, gcloud protects against this:
storage/parallel_composite_upload_compatibility_check(defaultTrue) skips PCU unless the object's storage class is STANDARD and the destination bucket has no retention policy and no default object holds — the conflict only arises if that check has been set toFalse. While Soft Delete and Object Versioning do not prevent PCU from working, they can significantly increase storage costs because deleted temporary components remain on the bucket.
For pipelines that compose objects themselves (chunked uploads merged with
gcloud storage objects compose), avoid those soft-delete/versioning costs by
hard-deleting the temporary components during composition instead of deleting
them afterwards: gcloud storage objects compose gs://B/chunk1 gs://B/chunk2 gs://B/final --delete-source-objects hard-deletes the source objects as part of
the compose operation, so they never become soft-deleted or noncurrent versions
while bucket-level protections stay on for the final objects.
B. Sliced Object Downloads
For downloading large files, the gcloud CLI executes ranged GET requests
(slices) in parallel, writing files concurrently into pre-allocated placeholders
in the local destination.
Checksum validation: To verify the data integrity of the downloaded slices,
gclouduses CRC32C checksums.Tuning Properties:
Threshold:
gcloud config set storage/sliced_object_download_threshold 0 # Set to 0 to disable sliced downloads
[!IMPORTANT] Sliced downloads require a compiled
crcmodPython package on the host machine. If a compiledcrcmodis not available,gcloudCLI prints a warning and automatically falls back to slower sequential downloading. By default,gclouddynamically autotunes slice triggers and components.
4. Scaling Concurrent Multi-File Transfers with gcloud CLI
gcloud storage is natively thread-safe and parallel by default.
Tuning Concurrency Controls
Concurrency inside gcloud is auto-tuned by default. If performance is poor or
resource limits are hit, process and thread values can be adjusted:
Process Count:
gcloud config set storage/process_count 8 # Or env variable: CLOUDSDK_STORAGE_PROCESS_COUNT=8Thread Count:
gcloud config set storage/thread_count 8 # Or env variable: CLOUDSDK_STORAGE_THREAD_COUNT=8
To disable concurrency entirely for sequential execution (e.g. debugging, rate
limit issues), set both values to 1:
gcloud config set storage/process_count 1
gcloud config set storage/thread_count 1To recursively upload or download directories containing many files, use the
--recursive or -r flag:
# Recursively upload a local directory to a bucket in parallel
gcloud storage cp -r ./local-directory gs://my-bucket/
# Recursively download a bucket prefix to a local directory in parallel
gcloud storage cp -r gs://my-bucket/backup-dir/ ./local-restore-dir/Syncing Directories with gcloud storage rsync
For synchronizing rather than copying, use rsync, which also runs in parallel
by default:
# Sync local directory to cloud (compares modification time and size, uploads missing/modified files, doesn't delete unmatched)
gcloud storage rsync ./my-data-folder gs://my-bucket/synced-data/ --recursive5. Storage Transfer Service (STS) for S3 and Azure Migrations
For multi-terabyte or petabyte-scale data transfers from Amazon S3, Microsoft Azure, or public/private HTTP sources to GCS, use the Storage Transfer Service (STS). STS runs transitions between cloud providers asynchronously on Google infrastructure without using local network or VM bandwidth. (Transfers from on-premises sources require deploying on-premises transfer agents).
STS also supports Amazon S3 sources in AWS GovCloud (US) regions
(us-gov-east-1 and us-gov-west-1), for both one-time/batch and event-driven
transfers. GovCloud sources use the arn:aws-us-gov: ARN prefix (for example
arn:aws-us-gov:iam::AWS_ACCOUNT:role/ROLE_NAME); transfers over the managed
private network are not available for GovCloud regions.
A. Prerequisites for Storage Transfer Service (STS)
Before creating a transfer job, complete the following steps:
Enable the API:
gcloud services enable storagetransfer.googleapis.comGrant the STS service agent access to the destination bucket: The service agent (
project-PROJECT_NUMBER@storage-transfer-service.iam.gserviceaccount.com) needsroles/storage.legacyBucketWriteron the destination bucket. If the overwrite option is set to check for "different" or "never", it also needsroles/storage.objectViewer.Grant permission command:
gcloud storage buckets add-iam-policy-binding gs://DESTINATION_BUCKET_NAME \ --member="serviceAccount:project-PROJECT_NUMBER@storage-transfer-service.iam.gserviceaccount.com" \ --role="roles/storage.legacyBucketWriter"
B. Credentials JSON File Setup
To authorize read access to your source without putting secret keys into CLI command arguments, construct a local JSON credential file.
For Amazon S3 (
s3-creds.json):{ "accessKeyId": "AWS_ACCESS_KEY_ID", "secretAccessKey": "AWS_SECRET_ACCESS_KEY" }For Azure Blob Storage (
azure-creds.json):{ "sasToken": "AZURE_SHARE_ACCESS_SIGNATURE_TOKEN" }
C. STS Commands
Create a Transfer Job from Amazon S3:
gcloud transfer jobs create s3://my-aws-s3-bucket/ gs://my-gcs-destination-bucket/ \
--source-creds-file=s3-creds.json \
--description="One-time S3 migration to GCS" \
--name="s3-to-gcs-migration"Create a Transfer Job from Azure Blob Storage:
Specify the Azure Blob Storage container endpoint as the source:
gcloud transfer jobs create https://myazurestorageaccount.blob.core.windows.net/mycontainer/ gs://my-gcs-destination-bucket/ \
--source-creds-file=azure-creds.json \
--description="One-time Azure container migration to GCS" \
--name="azure-to-gcs-migration"Additional STS CLI Operations:
Describe the job status and details:
gcloud transfer jobs describe s3-to-gcs-migrationRun a saved transfer job immediately:
gcloud transfer jobs run s3-to-gcs-migrationMonitor progress of the current transfer run in real time:
gcloud transfer jobs monitor s3-to-gcs-migrationList all existing STS transfer jobs:
gcloud transfer jobs list
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs an MCP server, Needs a command-line tool, Needs Node.js
Security
What our scanner noticed· Low risk
- Instructions that use the network
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Publisher
- Google (Official)
- Source
- google/skills · skills/cloud/google-cloud-storage-basics · commit 2194d3b
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Google.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download google-cloud-storage-basics.zip