Querying the List of OBS Buckets
Function
This API is used to query the list of OBS buckets.
This API can be used only when an agency is created. For details about how to create an agency, see Certificate Revocation > Creating an Agency in this document.
URI
GET /v1/private-certificate-authorities/obs/buckets
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
User token. The token can be obtained by calling the token API of IAM. The value of X-Auth-Token in the response header is the user token. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
total |
Integer |
Total number of the OBS buckets. |
obs_buckets |
Array of ObsBuckets objects |
For details, see data structure for the ObsBuckets field. |
Parameter |
Type |
Description |
---|---|---|
bucket_name |
String |
Bucket name Minimum: 3 Maximum: 63 |
create_time |
Long |
Creation time. The value is a timestamp in milliseconds. |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code Minimum: 3 Maximum: 36 |
error_msg |
String |
Error message Minimum: 0 Maximum: 1024 |
Status code: 401
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code Minimum: 3 Maximum: 36 |
error_msg |
String |
Error message Minimum: 0 Maximum: 1024 |
Status code: 403
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code Minimum: 3 Maximum: 36 |
error_msg |
String |
Error message Minimum: 0 Maximum: 1024 |
Status code: 404
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code Minimum: 3 Maximum: 36 |
error_msg |
String |
Error message Minimum: 0 Maximum: 1024 |
Status code: 500
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code Minimum: 3 Maximum: 36 |
error_msg |
String |
Error message Minimum: 0 Maximum: 1024 |
Example Requests
When you use this API to query the list of OBS buckets, a token is required in the X-Auth-Token field in the request header. The token must have the permission to access the API.
GET https://ccm.ae-ad-1.myhuaweicloud.com/v1/private-certificate-authorities/obs/buckets
Example Responses
Status code: 200
Request succeeded.
{ "total" : 2, "obs_buckets" : [ { "create_time" : 1554867690718, "bucket_name" : "admin1" }, { "create_time" : 1554949519646, "bucket_name" : "admin3" } ] }
Status code: 400
Invalid request parameters.
{ "error_code" : "PCA.XXX", "error_msg" : "XXX" }
Status code: 401
Token required for the requested page.
{ "error_code" : "PCA.XXX", "error_msg" : "XXX" }
Status code: 403
Authentication failed.
{ "error_code" : "PCA.XXX", "error_msg" : "XXX" }
Status code: 404
No resources available or found.
{ "error_code" : "PCA.XXX", "error_msg" : "XXX" }
Status code: 500
Internal service error.
{ "error_code" : "PCA.XXX", "error_msg" : "XXX" }
Status Codes
Status Code |
Description |
---|---|
200 |
Request succeeded. |
400 |
Invalid request parameters. |
401 |
Token required for the requested page. |
403 |
Authentication failed. |
404 |
No resources available or found. |
500 |
Internal service error. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot