Skip to content
Back to Steward

Presign a direct-to-S3 upload for one migration file

POST
/api/v1/migrations/{migrationId}/upload/sign
migrationId
required
string

Migration ID

object
fileName
required

Original file name (used for the staging key + display).

string
contentType
required

MIME content type the client will PUT with.

string
size
required

Total file size in bytes — decides single-PUT vs multipart.

number
object
strategy
required

Single presigned PUT (small) or S3 multipart (large).

string
Allowed values: put multipart
key
required

The staging S3 key the object will live at.

string
putUrl
required

Presigned PUT url. Present only when strategy = put.

string
nullable
uploadId
required

S3 multipart upload id. Present only when strategy = multipart.

string
nullable
partSize
required

Byte size of each part (except the last). Present only when strategy = multipart.

number
nullable
partCount
required

Total number of parts to upload. Present only when strategy = multipart.

number
nullable
Example
{
"strategy": "put",
"key": "string",
"putUrl": "string",
"uploadId": "string",
"partSize": 0,
"partCount": 0
}