GetContainerList
- Print
- PDF
GetContainerList
- Print
- PDF
Article Summary
Share feedback
Thanks for sharing your feedback!
Overview
Views the container (bucket) list.
Caution
The Subaccount can use it through the external API gateway dedicated to Subaccounts.
For more information, see Subaccount.
Syntax
GET v1/AUTH_{project_id}
Request
Request parameters
Name | In | Type | Description |
---|---|---|---|
limit (Optional) | query | integer | Maximum limit for the number of call results |
marker (Optional) | query | string | Gets the list after a specific container |
end_marker (Optional) | query | string | Gets the list before a specific container |
prefix (Optional) | query | string | Calls the container list starting with the string |
reverse (Optional) | query | string | Displays the list of container names in descending order default : false (descending) |
X-Auth-Token (Optional) | header | string | Enter the issued token value |
Accept (Optional) | header | string | Specifies the format of the call result (application/JSON, application/XML, text/XML) |
Response
Response header
Name | In | Type | Description |
---|---|---|---|
X-Account-Meta-name | header | string | - Metadata information of the account - The name part of the header name serves as the metadata's key. |
Content-Length | header | string | Length of the response result (bytes) |
X-Container-Object-Count | header | integer | Number of objects in the container (bucket) |
X-Container-Bytes-Used | header | integer | Total capacity size (bytes) used by the container (bucket) |
X-Container-Meta-Temp-URL-Key (Optional) | header | string | Secret key value for the temporary URL |
X-Container-Meta-Temp-URL-Key-2 (Optional) | header | string | Second secret key value for the temporary URL |
X-Timestamp | header | integer | Created time (Unix time) of the container (bucket) |
X-Trans-Id | header | string | Transaction ID of the request |
X-Openstack-Request-Id | header | string | Transaction ID of the request (same as X-Trans-Id) |
Content-Type | header | string | Format of the response result |
Date | header | string | Response time of the request (UTC) |
Response bodies
Name | In | Type | Description |
---|---|---|---|
name | body | string | Name of the object |
count | body | integer | Number of objects in the container (bucket) |
bytes | body | integer | Total capacity size (bytes) used by the container (bucket) |
last_modified | body | string | Time the container was last changed (UTC) |
Examples
Request examples (JSON)
curl -i -X GET -H "X-Auth-Token: $token" https://kr.archive.ncloudstorage.com/v1/AUTH_{project_id}/{container}?format=json
Response examples
HTTP/1.1 200 OK
Content-Length: 96
X-Account-Object-Count: 1
X-Timestamp: 1389453423.35964
X-Account-Meta-Subject: Literature
X-Account-Bytes-Used: 14
X-Account-Container-Count: 2
Content-Type: application/json; charset=utf-8
Accept-Ranges: bytes
X-Trans-Id: tx274a77a8975c4a66aeb24-0052d95365
X-Openstack-Request-Id: tx274a77a8975c4a66aeb24-0052d95365
Date: Fri, 17 Jan 2014 15:59:33 GMT
[
{
"count": 0,
"bytes": 0,
"name": "janeausten",
"last_modified": "2013-11-19T20:08:13.283452"
},
{
"count": 1,
"bytes": 14,
"name": "marktwain",
"last_modified": "2016-04-29T16:23:50.460230"
}
]
Request examples (XML)
curl -i -X GET -H "X-Auth-Token: $token" https://kr.archive.ncloudstorage.com/v1/AUTH_{project_id}?format=XML
Response examples
HTTP/1.1 200 OK
Content-Length: 262
X-Account-Object-Count: 1
X-Timestamp: 1389453423.35964
X-Account-Meta-Subject: Literature
X-Account-Bytes-Used: 14
X-Account-Container-Count: 2
Content-Type: application/xml; charset=utf-8
Accept-Ranges: bytes
X-Trans-Id: tx69f60bc9f7634a01988e6-0052d9544b
X-Openstack-Request-Id: tx69f60bc9f7634a01988e6-0052d9544b
Date: Fri, 17 Jan 2014 16:03:23 GMT
<?xml version="1.0" encoding="UTF-8"?>
<account name="my_account">
<container>
<name>janeausten</name>
<count>0</count>
<bytes>0</bytes>
<last_modified>2013-11-19T20:08:13.283452</last_modified>
</container>
<container>
<name>marktwain</name>
<count>1</count>
<bytes>14</bytes>
<last_modified>2016-04-29T16:23:50.460230</last_modified>
</container>
</account>
Upon successful request, it responds to OK (200) or No Content (204) status code.
No Content (204) status code is when the content type is plain and when no content exists for the request.
When the container (bucket) does not exist, it responds to the Not Found (403) status code.
Caution
The sub account must use the API list view dedicated to SubAccounts
Was this article helpful?