UploadPart
Updated at:2025-11-03
API description
After calling InitiateMultipartUpload and getting the UploadId, use the UploadPart command to upload the split object data (Part). Specify the partNumber parameter to indicate the relative position of each part in the object. The partNumber range is 1 - 10,000.
The size of a BOS Part is limited. Except for the last shard, each shard must be between 100 KB and 5 GB, with the entire object size capped at 48.8 TB.
Request
-
Request syntax
Plain Text1PUT /<ObjectName>?partNumber=PartNumber&uploadId=UploadId HTTP/1.1 2Host: <BucketName>.bj.bcebos.com 3Date: <Date> 4Authorization: <AuthorizationString> 5Content-Length: <ContentLength> -
Request headers
| Name | Types | Description |
|---|---|---|
| Content-MD5 | String | The MD5 digest of the HTTP request content, as defined in RFC 2616, verifies data consistency between the file stored in BOS and the one expected by the user. |
| x-bce-content-sha256 | String | This field verifies the consistency between the file stored on the BOS side and the file expected by the user. SHA256 ensures higher validation accuracy, and the transmitted data's SHA256 value must match; otherwise, UploadPart fails. |
| x-bce-content-crc32 | String | CRC32 value of the uploaded object (IEEE algorithm). |
| x-bce-content-crc32c | String | CRC32C value of the uploaded object (Castagnoli algorithm). |
| x-bce-content-crc32c-flag | String | Whether to calculate CRC32C, only effective when the value is "true". |
| Name | Types | Parameter location | Description | Whether required |
|---|---|---|---|---|
| partNumber | Int | Query | Relative position of the part uploaded this time within the object | Yes |
| uploadId | String | Query | UploadId obtained via InitiateMultipartUpload | Yes |
Response
| Name | Types | Description |
|---|---|---|
| ETag | String | ETag of each multipart uploaded |
| Others | - | Header field related to other RFC2616 |
Plain Text
1 > **Note**
2 >
3 > UploadPart returns the eTag of the current part. The eTag is needed in the third step of MultipartUpload. It's recommended to validate the uploaded data's accuracy using the eTag.
Example
-
Request example
Plain Text1PUT /ObjectName?partNumber=PartNumber&uploadId=UploadId HTTP/1.1 2Host: BucketName.bj.bcebos.com 3Date: Wed, 06 Apr 2016 06:34:40 GMT 4Authorization: AuthorizationString 5Content-length:2794 6Content-Type:text/plain 7[2794 bytes of object data] -
Response example
Plain Text1HTTP/1.1 200 OK 2x-bce-request-id: 4db2b34d-654d-4d8a-b49b-3049ca786409 3Date: Wed, 06 Apr 2016 06:34:40 GMT 4ETag: "b54357faf0632cce46e942fa68356b38" 5Content-Length: 0 6Connection: keep-alive 7Server: BceBos
