Skip to main content
POST
/
v1
/
buckets
/
{bucket_identifier}
/
uploads
/
batch
Batch Create Uploads
curl --request POST \
  --url https://api.mixpeek.com/v1/buckets/{bucket_identifier}/uploads/batch \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: application/json' \
  --header 'X-Namespace: <x-namespace>' \
  --data '
{
  "uploads": [
    {
      "filename": "<string>",
      "content_type": "<string>",
      "file_size_bytes": 10485760,
      "presigned_url_expiration": 3600,
      "metadata": {},
      "create_object_on_confirm": false,
      "object_metadata": {
        "category": "products",
        "priority": "high"
      },
      "blob_property": "video",
      "blob_type": "VIDEO",
      "file_hash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
      "skip_duplicates": true
    }
  ],
  "shared_metadata": {},
  "shared_object_metadata": {}
}
'
{
  "uploads": [
    {
      "upload_id": "<string>",
      "bucket_id": "<string>",
      "filename": "<string>",
      "content_type": "<string>",
      "presigned_url_expiration": 123,
      "s3_key": "<string>",
      "status": "PENDING",
      "create_object_on_confirm": true,
      "created_at": "2023-11-07T05:31:56Z",
      "expires_at": "2023-11-07T05:31:56Z",
      "file_size_bytes": 10485760,
      "presigned_url": "<string>",
      "metadata": {},
      "object_metadata": {},
      "blob_property": "<string>",
      "blob_type": "<string>",
      "file_hash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
      "skip_duplicates": true,
      "is_duplicate": false,
      "duplicate_of_upload_id": "upl_original123",
      "message": "<string>",
      "completed_at": "2024-01-15T10:35:00Z",
      "verified_at": "2024-01-15T10:35:00Z",
      "etag": "d41d8cd98f00b204e9800998ecf8427e",
      "object_id": "obj_a1b2c3d4e5f6",
      "task_id": "task_abc123"
    }
  ],
  "total": 123
}

Headers

Authorization
string
required

REQUIRED: Bearer token authentication using your API key. Format: 'Bearer sk_xxxxxxxxxxxxx'. You can create API keys in the Mixpeek dashboard under Organization Settings.

X-Namespace
string
required

REQUIRED: Namespace identifier for scoping this request. All resources (collections, buckets, taxonomies, etc.) are scoped to a namespace. You can provide either the namespace name or namespace ID. Format: ns_xxxxxxxxxxxxx (ID) or a custom name like 'my-namespace'

Path Parameters

bucket_identifier
string
required

The unique identifier of the bucket

Body

application/json

Request to generate multiple presigned URLs in a single request.

uploads
CreateUploadRequest · object[]
required

List of upload requests (max 100)

Required array length: 1 - 100 elements
shared_metadata
Shared Metadata · object

Metadata to apply to all uploads (merged with individual metadata)

shared_object_metadata
Shared Object Metadata · object

Object metadata to apply to all uploads (merged with individual)

Response

Successful Response

Response from batch upload request.

uploads
UploadResponse · object[]
required

Generated uploads with presigned URLs

total
integer
required

Total number of uploads created