POST
/
v1
/
buckets
/
{bucket_identifier}
/
batches
Create Batch
curl --request POST \
  --url https://api.mixpeek.com/v1/buckets/{bucket_identifier}/batches \
  --header 'Content-Type: application/json' \
  --data '{
  "object_ids": [
    "object_789",
    "object_101"
  ]
}'
{
  "batch_id": "batch_123",
  "bucket_id": "<string>",
  "status": "DRAFT",
  "object_ids": [
    "object_123",
    "object_456"
  ],
  "error": "Failed to process batch: Object not found",
  "type": "BUCKET",
  "manifest_key": "s3://bucket/manifest.json",
  "task_id": "task_123",
  "loaded_object_ids": [
    "<string>"
  ],
  "internal_metadata": {}
}

Headers

Authorization
string | null

Bearer token authentication using your API key. Format: 'Bearer your_api_key'. To get an API key, create an account at mixpeek.com/start and generate a key in your account settings. Example: 'Bearer sk_1234567890abcdef'

X-Namespace
string | null

Optional namespace for data isolation. This can be a namespace name or namespace ID. Example: 'netflix_prod' or 'ns_1234567890'. To create a namespace, use the /namespaces endpoint.

Path Parameters

bucket_identifier
string
required

The unique identifier of the bucket.

Body

application/json

The request model for creating a new batch.

object_ids
string[]
required

A list of object IDs to add to the batch.

Minimum length: 1
Examples:
["object_789", "object_101"]

Response

Successful Response

The base model for a batch.

bucket_id
string
required

The unique identifier of the bucket.

batch_id
string

The unique identifier of the batch.

Examples:

"batch_123"

status
enum<string>

The current status of the batch.

Available options:
PENDING,
IN_PROGRESS,
PROCESSING,
COMPLETED,
FAILED,
CANCELED,
UNKNOWN,
SKIPPED,
DRAFT
object_ids
string[]

A list of object IDs included in the batch.

Examples:
["object_123", "object_456"]
error
string | null

The error message if the batch failed to process.

Examples:

"Failed to process batch: Object not found"

type
enum<string>

The type of the batch.

Available options:
BUCKET,
COLLECTION
manifest_key
string | null

The S3 manifest key for the batch.

Examples:

"s3://bucket/manifest.json"

task_id
string | null

The task ID of the batch.

Examples:

"task_123"

loaded_object_ids
string[] | null

A list of object IDs that were successfully loaded into the batch.

internal_metadata
object | null

Internal engine/job metadata (e.g., job_id for provider).