---
title: "Complete a multipart file upload."
method: POST
path: "/files/{owner}/{repo}/{identifier}/complete/"
tags: ["files"]
---

# Complete a multipart file upload.

`POST /files/{owner}/{repo}/{identifier}/complete/`

Complete a multipart file upload.

## Request body

- PackageFileUploadRequest
  - `filename` string, required — Filename for the package file upload.
  - `md5_checksum` string — MD5 checksum for a POST-based package file upload.
  - `method` 'put_parts' | 'put' | 'post' | 'presigned' | 'unsigned_put' — The method to use for package file upload.
  - `sha256_checksum` string — SHA256 checksum for a PUT-based package file upload.

## Response `201`

The multipart upload was completed successfully.

- PackageFileUpload
  - `identifier` string, uri — The identifier for the file to use when creating packages
  - `upload_fields` object, nullable — The dictionary of fields that must be sent with POST uploads
  - `upload_headers` object, nullable — The dictionary of headers that must be sent with uploads
  - `upload_querystring` string, nullable — The querystring to use for the next-step POST or PUT upload
  - `upload_url` string, uri — The URL to use for the next-step POST or PUT upload

## Other responses

- `400` — The multipart upload could not be completed.
- `404` — Namespace (owner), repository or upload file not found
- `422` — Missing or invalid parameters (see detail).

---

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