List Parts

You can perform this operation to query all parts associated to a multipart upload.

Request Syntax

GET /ObjectName?uploadId=uploadid&max-parts=max&part-number-marker=marker HTTP/1.1
Host: bucketname.obs.cn-north-1.myhwclouds.com
Date: date
Authorization: auth

Request Parameters

This request uses parameters to specify associated parts to be listed. Table 1 describes the parameters.

Table 1 Request parameters

Parameter

Description

Required or Optional

uploadId

Indicates the ID of the multipart upload whose parts are to be listed.

Type: string

Default value: none

Required

max-parts

Sets the maximum number of parts to be listed.

Type: string

Default: 1000

Optional

part-number

-marker

Indicates the part after which the part listing begins. The OBS lists only parts with greater numbers than that specified by this parameter.

Type: string

Default: none

Optional

Request Headers

This request uses common headers. For details about common request headers, see Common Request Headers.

Request Elements

This request involves no elements.

Response Syntax

HTTP/1.1 status_code
Date: date
Content-Length: length

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ListPartsResult xmlns="http://obs.cn-north-1.myhwclouds.com/doc/2015-06-30/">
    <Bucket>BucketName</Bucket>
    <Key>object</Key>
    <UploadId>uploadid</UploadId>
    <Initiator>
        <ID>id</ID> 
        <DisplayName>displayname</DisplayName>
    </Initiator>
    <Owner>
        <ID>ownerid</ID>
        <DisplayName>ownername</DisplayName>
    </Owner>
    <StorageClass>storageclass</StorageClass>
    <PartNumberMarker>partNmebermarker</PartNumberMarker>
    <NextPartNumberMarker>nextPartnumberMarker</NextPartNumberMarker>
    <MaxParts>maxParts</MaxParts>
    <IsTruncated>true</IsTruncated>
    <Part>
        <PartNumber>partNumber</PartNumber>
        <LastModified>modifiedDate</LastModified>
        <ETag>etag</ETag>
        <Size>size</Size>
    </Part>
</ListPartsResult>

Response Headers

This response uses common headers. For details about common response headers, see Common Response Headers.

Response Elements

This response uses elements to provide details about the listed parts. Table 2 describes the elements.

Table 2 Response elements

Element

Description

ListPartsResult

Indicates the container for the response.

Type: container

Children: Bucket, Key, UploadId, PartNumberMarker, NextPartNumberMarker, MaxParts, IsTruncated, Part

Ancestor: none

Bucket

Indicates the name of the bucket to which the multipart upload was initiated.

Type: string

Ancestor: ListPartsResult

Key

Indicates the key of the object for which the multipart upload was initiated.

Type: string

Ancestor: ListPartsResult

UploadId

Indicates the ID that identifies the multipart upload whose parts are listed.

Type: string

Ancestor: ListPartsResult

Initiator

Indicates the container element that identifies who initiated the multipart upload.

Type: container

Children: ID, DisplayName

Ancestor: ListPartsResult

Owner

Indicates the container element that identifies the object owner. This element is the same as Initiator and compatible with Amazon S3. In S3, if a multipart upload is initiated by an IAM user, Initiator may differ from Owner.

Type: container

Children: ID, DisplayName

Ancestor: ListPartsResult

ID

Indicates the domain ID of initiator or owner.

Type: string

Ancestor: Initiator or Owner

DisplayName

Indicates the initiator name.

Type: string

Ancestor: Initiator or Owner

StorageClass

Indicates the storage type.

Type: enumeration

Valid value: STANDARD|STANDARD_IA|GLACIER

Ancestor: ListPartsResult

PartNumberMarker

Indicates the part number after which the part listing begins.

Type: integer

Ancestor: ListPartsResult

NextPartNumberMarker

Indicates the value of PartNumberMarker in the next request when the returned result is incomplete.

Type: Integer

Ancestor: ListPartsResult

MaxParts

Indicates the maximum number of parts that are returned.

Type: integer

Ancestor: ListPartsResult

IsTruncated

Indicates whether the returned part list is truncated. The value true indicates that the list was truncated and false indicates that the list was not truncated.

Type: boolean

Ancestor: ListPartsResult

Part

Indicates the container for elements related to a particular part.

Type: string

Children: PartNumber, LastModified, ETag, Size

Ancestor: ListPartsResult

PartNumber identifies a part.

PartNumber

Indicates the number that identifies a part.

Type: integer

Ancestor: ListPartsResult.Part

LastModified

Indicates the date at which a part was uploaded.

Type: date

Ancestor: ListPartsResult.Part

ETag

ETag of an uploaded part.

Type: string

Ancestor: ListPartsResult.Part

Size

Indicates the size of an uploaded part.

Type: integer

Ancestor: ListPartsResult.Part

Error Responses

  • If an AK or signature is invalid, OBS returns status code 403 Forbidden and error code AccessDenied.
  • If the requested bucket does not exist, OBS returns status code 404 Not Found and error code NoSuchBucket.
  • If the requested multipart upload does not exist, OBS returns status code 404 Not Found and error code NoSuchUpload.
  • If the requester does not have the READ permission for the requested bucket, OBS returns status code 403 Forbidden and error code AccessDenied.

For details about other error responses, see Table 1.

Registration