查询WKS存储
功能介绍
查询WKS存储。
调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
URI
GET /v1/{project_id}/persistent-storages
|
参数 |
是否必选 |
参数类型 |
描述 |
|---|---|---|---|
|
project_id |
是 |
String |
项目ID。 |
|
参数 |
是否必选 |
参数类型 |
描述 |
|---|---|---|---|
|
offset |
否 |
Integer |
查询的偏移量。 |
|
limit |
否 |
Integer |
单次查询的大小[1-100]。 |
|
storage_id |
否 |
String |
WKS存储ID。 |
|
name |
否 |
String |
查询名称,模糊匹配。 |
请求参数
|
参数 |
是否必选 |
参数类型 |
描述 |
|---|---|---|---|
|
X-Auth-Token |
否 |
String |
用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 |
响应参数
状态码:200
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
count |
Integer |
总数。 |
|
items |
Array of PersistentStorage objects |
存储列表。 |
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
id |
String |
WKS存储ID。 |
|
name |
String |
名称。 |
|
storage_metadata |
StorageMetadata object |
存储定义。 |
|
create_time |
String |
创建时间。 |
|
user_claim_count |
Integer |
个人目录声明数量。 |
|
share_claim_count |
Integer |
共享目录声明数量。 |
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
storage_handle |
String |
SFS文件系统名称。 |
|
storage_class |
String |
存储类型:
|
|
name |
String |
名称。 |
|
region |
String |
所在区域。 |
|
export_location |
String |
访问地址:protocol://[bucket-name].sfs3.[region-name].myhuaweicloud.com:port。 |
状态码:400
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
状态码:401
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
状态码:403
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
状态码:404
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
状态码:405
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
状态码:500
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
状态码:503
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
错误码,失败时返回。 |
|
error_msg |
String |
错误描述。 |
请求示例
GET /v1/a4da8115c9d8464ead3a38309130523f/persistent-storages?storage_id=94b8e5c7-008f-40d7-b59a-084de3638286
响应示例
状态码:200
成功响应。
{
"count" : 1,
"items" : [ {
"id" : "94b8e5c7-008f-40d7-b59a-084de3638286",
"name" : "user-file-persistent",
"storage_metadata" : {
"storage_handle" : "sfs-tmp",
"storage_class" : "sfs",
"name" : "sfs-tmp",
"region" : "cn-north-5",
"export_location" : "https://sfs3.cn-****myhuaweicloud.com:443"
},
"create_time" : "2023-06-08T07:08:09.412Z",
"user_claim_count" : 0,
"share_claim_count" : 0
} ]
}
状态码
|
状态码 |
描述 |
|---|---|
|
200 |
成功响应。 |
|
400 |
由于包含语法错误,当前请求无法被服务器理解。 |
|
401 |
鉴权失败。 |
|
403 |
没有操作权限。 |
|
404 |
找不到资源。 |
|
405 |
请求中指定的方法不被允许。 |
|
500 |
服务内部错误,具体返回错误码请参见错误码说明。 |
|
503 |
服务不可用。 |
错误码
请参见错误码。