ListBuckets
get
/n/{namespace_name}/b
Get a list of all BucketSummary items in a compartment. A BucketSummary contains only summary fields for the bucket and does not contain fields such as user-defined metadata. ListBuckets returns a BucketSummary containing at most 1000 buckets. To paginate through more buckets, use the returned opc-next-page value with the page request parameter. To use this and other API operations, you must be authorized in an IAM policy. If you are not authorized, talk to an administrator. If you are an administrator who needs to write policies to give users access, see "Managing Policies" (https://docs.oracle.com/en/engineered-systems/private-cloud-appliance/3.0-latest/user/user-usr-manage-policies.html).
Request
Supported Media Types
- application/json
Path Parameters
-
namespaceName(required): string
Minimum Length:
1
Pattern:[A-Za-z][A-Za-z0-9\\-_\\.]+
The Object Storage namespace used for the request.
Query Parameters
-
compartmentId(required): string
Minimum Length:
1
Maximum Length:255
The OCID of the compartment. -
fields: array[string]
Collection Format:
csv
Bucket summary in list of buckets includes the 'namespace', 'name', 'compartmentId', 'createdBy', 'timeCreated', and 'etag' fields. This parameter can also include 'tags' (freeformTags and definedTags). The only supported value of this parameter is 'tags'. Example tags.-
Allowed Values:
[ "tags" ]
-
-
limit: integer
Minimum Value:
1
Maximum Value:1000
For list pagination. The maximum number of results per page, or items to return in a paginated List call. 1 is the minimum, 1000 is the maximum.Default Value:100
-
page: string
Minimum Length:
1
Maximum Length:512
For list pagination. The value of the opc-next-page response header from the previous List call.Default Value:oracle.doceng.json.BetterJsonNull@2c07545f
-
sortBy: string
The optional field to sort the results by.Default Value:
NAME
Allowed Values:[ "ID", "NAME", "TIME_CREATED" ]
-
sortOrder: string
The sort order to use, either ascending (ASC) or descending (DESC).Allowed Values:
[ "ASC", "DESC" ]
Header Parameters
-
opc-client-request-id: string
The client request ID for tracing.
Response
Supported Media Types
- application/json
200 Response
A page of BucketSummary objects.
Headers
-
opc-client-request-id: string
Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging.
-
opc-next-page: string
For paginating a list of buckets. In the GET request, set the limit to the number of buckets items that you want returned in the response. If the opc-next-page header appears in the response, then this is a partial list and there are additional buckets to get. Include the header's value as the page parameter in the subsequent GET request to get the next batch of buckets. Repeat this process to retrieve the entire list of buckets. By default, the page limit is set to 25 buckets per page, but you can specify a value from 1 to 1000.
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : schema
Type:
Show Source
array
-
Array of:
object BucketSummary
To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, talk to an administrator.
Nested Schema : BucketSummary
Type:
object
To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, talk to an administrator.
Show Source
-
compartmentId(required):
string
The compartment ID in which the bucket is authorized.
-
createdBy(required):
string
The OCID of the user who created the bucket.
-
definedTags:
object definedTags
Additional Properties Allowed: additionalPropertiesDefined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"Operations": {"CostCenter": "42"}}
-
etag(required):
string
The entity tag (ETag) for the bucket.
-
freeformTags:
object freeformTags
Additional Properties Allowed: additionalPropertiesFree-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. Example: {"Department": "Finance"}
-
name(required):
string
The name of the bucket. Avoid entering confidential information. Example: my-new-bucket1
-
namespace(required):
string
The Object Storage namespace in which the bucket lives.
-
timeCreated(required):
string(date-time)
The date and time the bucket was created, as described in [RFC 2616](https://tools.ietf.org/html/rfc2616#section-14.29).
Nested Schema : definedTags
Type:
object
Additional Properties Allowed
Show Source
-
object additionalProperties
Additional Properties Allowed: additionalPropertiesKey-value pair representing a defined tag key and value, scoped to a namespace. Example: {"CostCenter": "42"}
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"Operations": {"CostCenter": "42"}}
Nested Schema : freeformTags
Type:
object
Additional Properties Allowed
Show Source
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. Example: {"Department": "Finance"}
Nested Schema : additionalProperties
Type:
object
Additional Properties Allowed
Show Source
-
object additionalProperties
The value of the tag. Only the String type is supported.
Key-value pair representing a defined tag key and value, scoped to a namespace. Example: {"CostCenter": "42"}
Nested Schema : additionalProperties
Type:
object
The value of the tag. Only the String type is supported.
Example Response (application-json)
[ { "namespace": "ansh8lvru1zp", "name": "MyBucket_1", "compartmentId": "ocid1.compartment.unique_ID", "createdBy": "ocid1.user.unique_ID", "timeCreated": "2016-08-09T01:11:38.639Z", "etag": "dc450b1e-a22c-479a-aae2-a5903e519661" }, { "namespace": "ansh8lvru1zp", "name": "MyBucket_2", "compartmentId": "ocid1.compartment.unique_ID", "createdBy": "ocid1.user.unique_ID", "timeCreated": "2016-08-09T00:41:50.236Z", "etag": "31e21d43-41e8-42b0-beb8-cc0baa50ef94" }, { "namespace": "ansh8lvru1zp", "name": "MyBucket_3", "compartmentId": "ocid1.compartment.unique_ID", "createdBy": "ocid1.user.unique_ID", "timeCreated": "2016-08-08T21:18:37.448Z", "etag": "ed042fb0-a22f-48cc-a6d3-5590ee0bd0d2" }, { "namespace": "ansh8lvru1zp", "name": "MyBucket_4", "compartmentId": "ocid1.compartment.unique_ID", "createdBy": "ocid1.user.unique_ID", "timeCreated": "2017-01-20T00:25:55.758Z", "etag": "21edf865-d3d9-424f-8218-37188e803db8" }, { "namespace": "ansh8lvru1zp", "name": "MyBucket_5", "compartmentId": "ocid1.compartment.unique_ID", "createdBy": "ocid1.user.unique_ID", "timeCreated": "2017-01-20T19:12:41.886Z", "etag": "30d83c79-dd32-4c07-ace9-9240ed7083fd" } ]
400 Response
Bad Request
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload
401 Response
Unauthorized
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload
404 Response
Not Found
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload
408 Response
Request Timeout
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload
429 Response
Too Many Requests
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload
500 Response
Internal Server Error
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload
Default Response
An error has occurred.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing..Example:
UnknownError
-
message(required):
string
A human-readable error string.Example:
error validating payload