---
title: "Confirm Assembly Upload"
method: POST
path: "/api/v1/projects/{project_id}/assembly-file/confirm-upload"
tags: ["assembly-files"]
---

# Confirm Assembly Upload

`POST /api/v1/projects/{project_id}/assembly-file/confirm-upload`

Confirm the browser PUT to R2 completed; queue magic-bytes validation.

Transitions the row from ``uploading`` -> ``uploaded`` and kicks off
the validation Temporal workflow on the light worker.

## Path parameters

- `project_id` string, uuid, required

## Request body

- ConfirmAssemblyUploadRequest — Confirm that the browser PUT to R2 completed successfully. Transitions the row from ``uploading`` -> ``uploaded`` and queues the magic-bytes validation activity on the light worker.
  - `assembly_file_id` string, uuid, required — The ProjectAssemblyFile ID returned by the initiate endpoint.
  - `r2_key` string, required — R2 object key from initiate endpoint (echoed back for verification).

## Response `201`

Successful Response

- AssemblyFileResponse — Full assembly file metadata + presigned GET URL when validated.
  - `id` string, uuid, required
  - `project_id` string, uuid, required
  - `file_name` string, required
  - `file_size` integer, required
  - `file_format` 'step' | 'stp', required — Allowed formats for project-level assembly reference files. Intentionally a narrow subset — assembly files are reference docs only, not processed through the geometry pipeline.
  - `status` 'uploading' | 'uploaded' | 'validated' | 'failed', required — Lifecycle for ``ProjectAssemblyFile``. UPLOADING: presigned URL issued, waiting on browser PUT UPLOADED: confirm received; magic-bytes validation queued VALIDATED: passed magic-bytes check; downloadable FAILED: validation rejected (``failure_reason`` populated)
  - `failure_reason` string, nullable
  - `uploaded_by_user_id` string, uuid, nullable
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `download_url` string, nullable — Presigned GET URL for downloading the assembly file. None when status is not 'validated' (file isn't ready or has failed).

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/prototyping/apis/prototyping-io-api.md) · [All operations](https://skmtc.dev/prototyping/apis/prototyping-io-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/prototyping/prototyping-io-api/revisions/f4a0079fbb57/schema)
