/upload/multipart/{upload_id}/part/{part_number}
For general information on the API, including formatting, parameters, and pagination, please see the API Overview.
This call returns the signed URL required to upload a part of a multipart upload. Once you have obtained this URL for your file part, you can make a PUT
request to it with the file part as the request body.
https://cavatica-api.sbgenomics.com/v2/upload/multipart/{upload_id}/part/{part_number}
Request
Example request
GET /v2/upload/multipart/srand0mB1h7n3UcjUEqcHKahAl1cizencbI1OQvIkGv8qQRDiP2VAtUpO8NnLKFN/part/1 HTTP/1.1
Host: cavatica-api.sbgenomics.com
X-SBG-Auth-Token: 3259c50e1ac5426ea8f1273259740f74
curl -s -H "X-SBG-Auth-Token: 3259c50e1ac5426ea8f1273259740f74" -H "content-type: application/json" -X GET "https://cavatica-api.sbgenomics.com/v2/upload/multipart/EXAMPLE_ID/part/1"
Header Fields
Name | Description |
---|---|
X-SBG-Auth-Token required | Your CAVATICA authentication token. |
Content-Type required | application/json |
Path parameters
Name | Description |
---|---|
upload_id | The ID for the upload, returned by the call to initialize a multipart upload. |
part_number | The number of the file part you are uploading. Part numbers start from 1. |
Response
See a list of CAVATICA-specific response codes that may be contained in the body of the response.
Response body
The response object contains information about the URL to which you should upload the file part. The information is structured using the following key-value pairs:
Key | Data type | Description |
---|---|---|
method | String | The HTTP method to use when making the HTTP part upload request. |
url | String | The URL to which to make the HTTP part upload request. |
expires | Integer | ISO 8601 combined date and time representation in Coordinated Universal Time (UTC) by when the HTTP part upload request should be made. |
headers | Object | A map of headers and values that should be set when making the HTTP part upload request. |
report | Object | See the Structure of the report object section below for an explanation of the report object. |
success_codes | Array of Integers | A list of status codes returned by the HTTP part upload request that should be recognized as success. A successful part upload request should be reported back to the API in a call to report an uploaded file part by passing the information collected from the report object. |
Structure of the report
object
report
objectThis object instructs you which pieces of information need to be collected from a successful response to the HTTP part upload request.
Key | Data type | Description |
---|---|---|
headers | Array of Strings | A list of HTTP headers whose values should be collected from a successful response to the HTTP part upload request. |
body | Object | Reserved for future use |
Example response body
{
"method": "PUT",
"url": "https://bucket.s3.amazonaws.com/aa8a1030-7e27-4da4-b42b-39658b795d61%2BCanFam3.1.dna_rm.toplevel.fa.gz?uploadId=lMEXAMPLEqHsCNj9IKV4VytwZOy0.4ZKFPDD73CwEXAMPLExFXKZLHrqDi0kZt0jTm25PYJqNfEJDF9OaJ6Xvg8vLv9K7SJ.RLiCczfeXamPlezNQd78vmSK3a9Bkgx2&partNumber=1&AWSAccessKeyId=AKIAJF4ANIHWEXAMPLE&Expires=1459113561&Signature=3myrand0m0C11jkmjEXAMPLENo%3D",
"expires": "2016-02-27T15:55:38Z",
"headers": {},
"report": {
"success_codes": [
200
],
"headers": [
"ETag"
]
}
}