---
title: "Upload a file (multipart/form-data, part \"file\"). Same validation, limits and normalization as the web uploader."
method: POST
path: "/v1/files"
---

# Upload a file (multipart/form-data, part "file"). Same validation, limits and normalization as the web uploader.

`POST /v1/files`

## Request

- Base URL: `https://api.lumeta.ai`
- URL: `https://api.lumeta.ai/v1/files`
- Auth: HTTP bearer

## Response `201`

OK

- File
  - `id` string
  - `filename` string
  - `source` string
  - `project` string, nullable
  - `created_at` string
  - `type` 'image' | 'video' | 'audio' | 'other'
  - `url` string: Durable https URL of the stored file.
  - `mime` string, nullable
  - `width` integer
  - `height` integer
  - `duration` number: Seconds, for audio and video.
  - `size` integer: Bytes.

## Other responses

- `default`: Error

---

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