List user buckets

Content Platform for Cloud Scale Management API Reference

Version
2.5.x
Audience
anonymous
Part Number
MK-HCPCS007-08

You can retrieve a list of buckets owned by users of the HCP for cloud scale system by user ID and bucket name. You can also filter the list to retrieve a subset.

HTTP request syntax (URI)

POST https://host_ip:9099/mapi/v1/user/list_buckets

Request structure

The request body is:

{
  "id": "uuid",
  "count": [nnnn],
  "startingAfter": ["string"]
}
Parameter Required Type Description
id Yes UUID The ID of the user.
count No Integer The number of buckets to return. Up to 1000 buckets; default: 1000.
startingAfter No String The bucket name to start after alphabetically. Leave blank to start from the beginning of the list. Use this parameter to retrieve bucket lists in groups.

Response structure

Note: If the user ID provided does not exist, the response is an empty list.

The response body structure is:

[
  {
    "bucketId": "",
    "bucketName": ""
  },
  .
  .
  .
]

Parameter

Type

Description

bucketId UUID The UUID of the bucket.
bucketName String The display name of the bucket.

Return codes

Status code

HTTP name

Description

200 OK The request was executed successfully.
400 Bad Request The request is missing a valid parameter.
401 Unauthorized Access was denied because credentials are not valid.
405 Method Not Allowed The specified HTTP method is not allowed for user data. Resend using POST.

Example

Request example:

POST https://10.10.24.195:9099/mapi/v1/user/list_buckets

JSON request:

{
  "id": "3fa85f64-0810-1954-b3fc-2c963f66afa6",
  "count": 1,
  "startingAfter": "September"
}

JSON response:

[
  {
    "bucketId: "9b805cee-56aa-42a7-b89e-9087d6ade984",
    "bucketName": "October"
  }
]