---
title: "Complete a file upload and trigger processing"
method: POST
path: "/api/v1/datasets/{dataset_id}/upload/complete"
tags: ["Dataset"]
---

# Complete a file upload and trigger processing

`POST /api/v1/datasets/{dataset_id}/upload/complete`

## Request

- The document declares no server URL.
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/adaptionlabs/apis/adaption-api/docs/api/v1/datasets/:dataset_id/upload/complete/post.ts> (a function with typed inputs; its response is checked against the schema)

File uploads only. Call after uploading bytes to the presigned URL from POST /datasets. Verifies the file exists in S3, then triggers the preprocessing pipeline. TXT files are converted to rows here. Documents (pdf, docx, pptx, xlsx, html, or a zip holding them) are not: the dataset then reports `awaiting_input` until POST /datasets/{dataset_id}/launch-preprocessing extracts them.

## Path parameters

- `dataset_id` string, required

## Request body

- CompleteUploadByIdDto
  - `file_size_bytes` number, required: Size of the uploaded file in bytes (for verification)
  - `sha256` string: SHA-256 hex digest of the uploaded file (for integrity verification)

## Response `200`

- CompleteUploadByIdResponseDto
  - `dataset_id` string, required: ID of the dataset
  - `status` string, required: Current status of the dataset after completing upload

---

[API](https://skmtc.dev/adaptionlabs/apis/adaption-api.md) - [All operations](https://skmtc.dev/adaptionlabs/apis/adaption-api/llms.txt) - [OpenAPI document](https://skmtc.dev/adaptionlabs/apis/adaption-api/revisions/d4cf908c19a0?raw)
