Overview of request methods for the XML API Stay organized with collections Save and categorize content based on your preferences.
The Cloud Storage XML API supports several standard HTTP request methods.Each method can use numerous request headers and response headers. The XML APIdocumentation describes all of the supported HTTP methods as well as the mostfrequently used headers for each method.
Some methods are used to work with both data and metadata depending on context.For example, you can use one PUT Bucket request to create a bucket followed by asecond PUT Bucket request to configure logging for the bucket.
The following list shows which XML API method you use to accomplishbucket and object tasks.
- GET Service
- List Buckets in the project
- DELETE Bucket
- Delete a Bucket
- GET Bucket
- HEAD Bucket
- checks bucket existence
- PUT Bucket
- DELETE Object
- GET Object
- HEAD Object
- Gets Object Metadata
- POST Object
- PUT Object
- GET HMAC Key
- POST HMAC Key
Conventions used
Conventions used in the XML API documentation:
The
Authorizationheader is represented as<authentication string>. Ifyou are using the XML API to migrate from another storage provider, then theAuthorizationhas the format discussed inAuthentication in a Simple Migration Scenario.Otherwise, theAuthorizationheader has the formatdiscussed inOAuth 2.0 Authentication.If you do not provide authorization information when required to perform arequest, the Cloud Storage issues a 401 unauthorized error. For moreinformation, seeStatus Codes.
The
Hostheader used in the XML API documentation is of the form: where the bucket name is specified as part of the hostname. In alloperations except GET service, you can also specify the bucket as part ofthe URL path. For more information, seeRequest Endpoints.Host:BUCKET-NAME.storage.googleapis.com
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-12-17 UTC.