Listing Object Storage Buckets

View a list of the Object Storage buckets in a compartment.

    1. Open the navigation menu  and select Storage. Under Object Storage & Archive Storage, select Buckets.
      The Buckets list page opens. All buckets in the selected compartment are displayed in a table.
    2. To view the buckets in a different compartment, use the Compartment filter to switch compartments.
      You must have permission to work in a compartment to see the resources in it. If you're not sure which compartment to use, contact an administrator. For more information, see Understanding Compartments.

    Filtering List Results

    Use filters to limit the buckets in the list. Perform one of the following actions depending on the options that you see:

    • From the Search and Filter box above the list table, select one or more filters and specify the values that you want to use to narrow the list. In general, the filters correspond to the columns shown in the list table, although some filters represent attributes that aren't shown in the table. The Compartment filter is always displayed next to Applied filters.
    • On the left side of the list page, select a value from one of the available filters, such as compartment, state, or tags.

    Change the order of the items in the list table by using the sort icons next to the column names.

    For information about searching for resources and managing the columns in the list table, if those features are available, see Listing Resources.

    Actions

    In the list table, select the name of a bucket to open its details page, where you can view its status and perform other tasks.

    To perform an action on a bucket directly from the list table, select any of the following options from the Actions menu in the row for that bucket:

    To create a bucket, select Create bucket.

  • Use the oci os bucket list command and required parameters to list the buckets in a compartment:

    oci os bucket list --compartment-id compartment_ocid [OPTIONS]

    For example:

    oci os bucket list --compartment-id ocid.compartment.oc1..exampleuniqueID --namespace MyNamespace					
    {
      "data": [
        {
          "compartment-id": "ocid.compartment.oc1..exampleuniqueID",
          "created-by": "ocid1.user.oc1..exampleuniqueID",
          "defined-tags": null,
          "etag": "c8889cd1-8414-41fb-84b7-3738c39e62c5",
          "freeform-tags": null,
          "name": "MyStandardBucket",
          "namespace": "MyNamespace",
          "time-created": "2020-05-22T19:22:25.032000+00:00"
        },
        {
          "compartment-id": "ocid.compartment.oc1..exampleuniqueID",
          "created-by": "ocid1.user.oc1..exampleuniqueID",
          "defined-tags": null,
          "etag": "7b7c3dc1-713f-4996-b176-a938345cae8e",
          "freeform-tags": null,
          "name": "MyArchiveBucket",
          "namespace": "MyNamespace",
          "time-created": "2020-06-22T13:04:05.879000+00:00"
        }
      ]
    }				

    By default, getting a list of buckets returns up to the first 1,000 buckets in the compartment.

    For a complete list of parameters and values for CLI commands, see the CLI Command Reference.

    Using Field Tags

    By default when listing buckets, null is returned as the value for both free-form and defined tags. To include resource tag data, include the --fields tags parameter:

    oci os bucket list --compartment-id compartment_ocid --fields tags [OPTIONS]

    For example:

    oci os bucket list --compartment-id ocid.compartment.oc1..exampleuniqueID --fields tags
    {
      "data": [
    	{
    	  "compartment-id": "ocid1.compartment.oc1..exampleuniqueID",
    	  "created-by": "ocid1.user.oc1..exampleuniqueID",
    	  "defined-tags": {
    		"example_tag_namespace_Financials": {
    		  "production": "Unit 5"
    		},
    		"example_tag_namespace_Operations": {
    		  "costcenter": "85"
    		}		
    	  },
    	  "etag": "48af18cf-1edd-4b05-9f36-a629d5032260",
    	  "freeform-tags": {
    	    "Project": "prototype 3"
    	  },
    	  "name": "MyStandardBucket",
    	  "namespace": "MyNamespace",
    	  "time-created": "2020-05-27T18:52:16.951000+00:00"
    	}
      ]
    }
  • Run the ListBuckets operation to list the buckets in a compartment.

    When accessing the Object Storage API, the bucket name is used with the Object Storage namespace name to form the request URL:

    n/object_storage_namespace/b/bucket