---
title: "Upload a file to a collection"
method: POST
path: "/api_partner/collections/{collection_slug}/files"
tags: ["Collections"]
---

# Upload a file to a collection

`POST /api_partner/collections/{collection_slug}/files`

## Request

- Base URL: `https://api.scite.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.scite.ai/api_partner/collections/{collection_slug}/files`
- Auth: HTTP bearer

The user named by `email` must be a member of the Collection, and the file is attributed
to them. The type is identified from the bytes, not the name or a declared content type.

## Path parameters

- `collection_slug` string, required

## Query parameters

- `email` string, email, required

## Headers

- `authorization` string: Set to `Bearer <token>` to pass token for authorization.

## Request body `multipart/form-data`

- BodyPartnerUploadCollectionFileApiPartnerCollectionsCollectionSlugFilesPost
  - `file` string, binary, required

## Response `200`

Successful Response

- CollectionFileSchema
  - `id` integer, required
  - `dashboardId` integer, required
  - `targetType` 'COLLECTION'
  - `filename` string, required
  - `contentType` string, required
  - `byteSize` integer, required
  - `createdByEmail` string, nullable
  - `createdByName` string, nullable
  - `createdAt` string, date-time, required
  - `lastUpdated` string, date-time, required
  - `suspended` boolean

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-01** `97e32261f535`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/scite/apis/scite-api/changes/api_partner/collections/:collection_slug/files/post.md)

---

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