GetService

최신 업데이트:2022-03-01 18:22:26

Function Description

The GetService interface is used to obtain all the buckets of the user in the area. In the case a user has buckets in multiple areas, only the bucket belonging to that area is listed. This operation requires IAM permission wos:GetGetService.

Request Syntax

GET / HTTP/1.1
Host: Bucket.Endpoint
Date: Date
Authorization: Authorization

Request parameter

There are no request parameters in the request message.

Request header

Use common request headers .

Request body

No request body.

Response syntax

HTTP/1.1 StatusCode
x-wos-request-id: RequestId
Date: Date
Content-Type: type
Content-Length: length
Server: WS-web-server
 
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ListAllMyBucketsResult xmlns="https://www.wangsu.com/document">
    <Owner>
        <ID>id</ID>
        <DisplayName>name</DisplayName>
    </Owner>
    <Buckets>
        <Bucket>
            <Name>bucketName</Name>
            <CreationDate>date</CreationDate>
        </Bucket>
        ...
    </Buckets>
</ListAllMyBucketsResult>

Response header

Use common response headers .

Response body

In the response message of this request, the space owned by the user will be listed in XML form. The specific meaning of the elements is shown in the following table.

Element NameDescription
ListAllMyBucketsResultThe user's space list.

Type: XML.
OwnerUser information, including user ID and user name.

Type: XML.
IDThe DomainId of the user.

Type: string.
DisplayNameusername.

Type: string.
BucketsThe list of spaces owned by the user.

Type: XML.
BucketSpecific spatial information.

Type: XML.
NameSpace name.

Type: string.
CreationDateThe creation time of the space.

Type: string.

Example

Request example

GET / HTTP/1.1
Host: s3-cn-south-1.wcsapi.com
Date: Wed, 04 Nov 2020 03:09:24 GMT
Authorization: WOS-HMAC-SHA256 BF6C09F302931425E9A7:tQ+A280jUgPCAdSTuUis35T9gWI=

Response example

HTTP/1.1 200 OK
x-wos-request-id: 9D3CC717E561E4D37A1285489689346
Content-Type: application/xml
Date: Sun, 26 Sep 2010 08:28:06 GMT
Content-Length: 485
Server: WS-web-server
 
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ListAllMyBucketsResult xmlns="http://wcs.chinanetcenter.com/document">
    <Owner>
        <ID>bcaf1ffd86f41caff1a493dc2ad8c2c281e37522a640e161ca5fb16fd081034f</ID>
        <DisplayName>user01</DisplayName>
    </Owner>
    <Buckets>
        <Bucket>
            <Name>bucket01</Name>
            <CreationDate>2010-09-26T03:10:23.211Z</CreationDate>
        </Bucket>
        <Bucket>
            <Name>bucket02</Name>
            <CreationDate>2010-09-20T12:05:46.187Z</CreationDate>
        </Bucket>
        <Bucket>
            <Name>bucket03</Name>
            <CreationDate>2010-09-26T08:25:13.059Z</CreationDate>
        </Bucket>
    </Buckets>
</ListAllMyBucketsResult>

이 문서의 내용이 도움이 되었습니까?
아니오
정상적으로 제출되었습니다.피드백을 주셔서 감사합니다.앞으로도 개선을 위해 노력하겠습니다.