ColdStack Docs
  • Introduction
  • ColdStack FAQ
  • Binance Smart Chain Bridge
    • Release
    • Customer Support
    • FAQ
    • Step-by-Step Guide
  • Concepts
    • Bucket versioning
    • Logging actions with a bucket
  • Tools
    • Supported tools
      • CyberDuck S3 Client
      • S3 Browser
      • AWS CLI Console client
      • SDKs for different languages
        • JavaScript SDK
        • Using extended API with JavaScript
        • AWS SDK for Java
        • Python SDK (boto)
  • S3 Compatible API
    • How to use the API
    • Signing Requests
    • API Reference
      • Bucket
        • HeadBucket
        • ListObjects/ListObjectsV2
        • PutBucketVersioning
        • PutBucketLogging
        • RenameBucket
        • GetBucketLocation
        • ListBuckets
      • Object
        • PutObject
        • GetObject
        • HeadObject
        • RenameObject
        • PutObjectAcl
      • Multipart upload
        • General multipart upload order
        • CreateMultipartUpload
        • UploadPart
        • CompleteMultipartUpload
        • ListMultipartUploads
      • Analytics
        • GetStatistics
        • GetBandwidthAnalytics
        • GetStorageAnalytics
      • Common request headers
      • Common response headers
      • Responses
Powered by GitBook
On this page
  • Request
  • Answer

Was this helpful?

  1. S3 Compatible API
  2. API Reference
  3. Multipart upload

CompleteMultipartUpload

PreviousUploadPartNextListMultipartUploads

Last updated 4 years ago

Was this helpful?

The request completes the composite download.

When receiving an Object Storage request:

  • Assembles the final object from the parts obtained during the download process in the order of their numbers

  • Removes the download ID so that all subsequent requests with the download ID will return an error NoSuchUpload.

When the download is complete, the client must provide a list of the parts that he sent. The description of each part should contain ETag, which the client receives in response to each downloaded part. See section .

Depending on the size of the object and the number of parts, the operation may take several minutes.

If the request fails, then the client application should be ready to retry the request.

Request

POST /{bucket}/{key}?uploadId=UploadId HTTP/1.1

Path parameters

Parameter

Description

bucket

Bucket name.

key

Object key.

Query parameters

Parameter

Description

uploadId

Headings

Data schema

The list of parts of a composite download is sent as an XML file in the following format:

<CompleteMultipartUpload>
  <Part>
    <PartNumber>PartNumber</PartNumber>
    <ETag>ETag</ETag>
  </Part>
  ...
</CompleteMultipartUpload>

Tag

Description

CompleteMultipartUpload

Request data. Path: /CompleteMultipartUpload.

Part

Data about the loaded part of the object. Path: /CompleteMultipartUpload/Part.

PartNumber

Part number. A unique identifier that identifies the position of the part among other parts in the load. Path: /CompleteMultipartUpload/Part/PartNumber.

ETag

The identifier that the client received from ColdStack in response to downloading the part. Path: /CompleteMultipartUpload/Part/ETag.

Answer

Headings

Answer codes

Additionally, ColdStack may return the errors described in the table below.

Mistake

Description

HTTP code

NoSuchUpload

The specified download does not exist. The download ID may be incorrect, or the download may have completed or been deleted.

404 Not Found

InvalidPart

Some of the specified parts have not been found. Possible causes: - Parts not loaded. - The transmitted one ETagdoes not match the saved one.

400 Bad Request

InvalidPartOrder

The list of parts is not transmitted in ascending order. The list should be sorted in ascending order by part number.

400 Bad Request

The successful response contains additional data in XML format, the schema of which is described below.

Data schema

<CompleteMultipartUploadResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
  <Location>http://Example-Bucket.s3.coldstack.io/Example-Object</Location>
  <Bucket>Example-Bucket</Bucket>
  <Key>Example-Object</Key>
  <ETag>"3858f62230ac3c915f300c664312c11f-9"</ETag>
</CompleteMultipartUploadResult>

Tag

Description

CompleteMultipartUploadResult

Response data. Path: /CompleteMultipartUploadResult.

Location

The URI of the resulting download of the object. Path: /CompleteMultipartUploadResult/Location.

Bucket

The name of the bucket in which the object is located. Path: /CompleteMultipartUploadResult/Bucket.

Key

The key of the created object. Path: /CompleteMultipartUploadResult/Key.

ETag

The hash of the object. ETag may or may not be MD5. Path: /CompleteMultipartUploadResult/ETag.

The composite load ID that ColdStack returned upon .

Use the required in the request .

The response can only contain .

For a list of possible answers, see the section .

The UploadPart Method
common headers
general headers
Answers
initialization