---
title: "Upload assets to a dataset"
method: POST
path: "/datasets/{dataset_id}/upload_assets"
tags: ["datasets"]
---

# Upload assets to a dataset

`POST /datasets/{dataset_id}/upload_assets`

Upload image assets to a dataset for model training. Accepts individual images (JPEG, PNG, WebP), optional .txt caption sidecar files, and/or ZIP archives containing images and captions. A dataset can contain up to 100 images.

## Path parameters

- `dataset_id` string, required

## Headers

- `Api-Key` string, required

## Response `200`

Upload summary

- UploadDatasetAssetsResponse
  - `total_count` integer, required — Total number of images processed.
  - `success_count` integer, required — Number of images successfully uploaded.
  - `failure_count` integer, required — Number of images that failed to upload.
  - `successful_assets` DatasetUploadSucceededAsset[] — Details of successfully uploaded assets.
    - `asset_identifier` AssetIdentifier, required — An identifier for an ideogram asset.
      - `asset_type` 'ASSET' | 'CANVAS_ASSET' | 'LAYERED_ASSET' | 'RESPONSE' | 'UPLOAD', required
      - `asset_id` string, required
    - `file_name` string, nullable — Original filename of the uploaded file. For a caption sidecar (.txt or .json) this is the sidecar's filename, and asset_identifier points to the image the caption was applied to. A single image therefore yields one entry for the image plus one per caption file.
  - `failed_assets` DatasetUploadFailedAsset[] — Details of assets that failed to upload.
    - `file_name` string, nullable — Original filename of the failed image.
    - `failure_reason` 'FAILED_SAFETY_CHECK' | 'FILE_TOO_LARGE' | 'INTERNAL_ERROR' | 'INVALID_CAPTION' | 'INVALID_CAPTION_JSON' | 'INVALID_IMAGE' | 'INVALID_ZIP' | 'TOO_MANY_IMAGES', required — Reason why an asset failed to upload.

## Other responses

- `400` — Bad request
- `401` — Unauthorized
- `404` — Dataset not found

---

[API](https://skmtc.net/ideogram/apis/api-reference.md) · [All operations](https://skmtc.net/ideogram/apis/api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ideogram/api-reference/versions/f6a8c81158c0/schema)
