Access to Cloud Storage through the XML API is useful when you are working with tools and libraries that must work across different storage providers, or when you are migrating from another storage provider to Cloud Storage. In the latter case, you only need to make a few simple changes to your existing tools and libraries to begin sending requests to Cloud Storage. For more information about migrating to Cloud Storage, see Migrating from Amazon S3 to Google Cloud Storage.
The following table summarizes examples of using the Google Cloud Storage XML API. Each example page provides information about how to set up your environment, what OAuth 2.0 credential type to use, and how to run the sample.
|Language||OAuth 2.0 credential||API actions demonstrated|
|Java Examples||Application Default Credentials||The command-line example lists the contents of a bucket. The second example shows how to access Google Cloud Storage from Google App Engine.|
|Python Example||Installed Application||Common tasks like listing buckets, uploading and listing objects, and downloading objects.|
These examples demonstrate how to use OAuth 2.0 credentials for the service account and installed application scenarios. For more information, see Using OAuth 2.0 to Access Google APIs.