---
title: "Update file"
method: PATCH
path: "/files/{id}"
tags: ["Files"]
---

# Update file

`PATCH /files/{id}`

## Request

- Base URL: `https://api.crevio.co/v1`
- URL: `https://api.crevio.co/v1/files/{id}`
- Auth: API key in header `Authorization`

Updates a file's mutable metadata. The stored bytes are immutable — re-upload to change a file's contents.

All fields are optional and follow PATCH semantics: only the fields you send are changed. For files you can rename via `filename` and set a `description` or `tags`. For external-video embeds you can update the source `url`.

## Path parameters

- `id` string, required

## Request body

- FileUpdateRequest
  - `title` string, nullable: Human-readable display title. Pass null to clear it.
  - `filename` string, nullable: Rename the file (updates the stored blob filename). Files only.
  - `description` string, nullable: Free-text description. Pass null to clear it.
  - `tags` string[], nullable: Replaces the tag list. Pass an empty array to clear all tags.
  - `url` string, nullable: New source URL for an external-video embed (YouTube, Vimeo, or Wistia).

## Response `200`

Updated file

- File
  - `object` string, required
  - `id` string, required
  - `kind` 'file' | 'external_video', required
  - `upload_status` 'pending' | 'processing' | 'ready' | 'failed', required
  - `source` 'upload' | 'url_import' | 'external_video' | 'generation', required
  - `title` string, nullable, required
  - `description` string, nullable, required
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `url` string, nullable, required
  - `tags` string[], nullable, required
  - `source_job_id` string, nullable, required
  - `filename` string, nullable, required
  - `content_type` string, nullable, required
  - `size` integer, nullable, required
  - `provider` string, nullable, required
  - `file_url` string, nullable, required

## Other responses

- `400`: Bad request
- `401`: Authentication required
- `403`: Forbidden
- `404`: Resource not found
- `422`: Validation error
- `429`: Rate limit exceeded — 600 requests per minute per credential. Retry after the number of seconds in `Retry-After`.
- `500`: Internal server error

---

[API](https://skmtc.dev/crevio/apis/crevio-api-v1.md) · [All operations](https://skmtc.dev/crevio/apis/crevio-api-v1/llms.txt) · [OpenAPI document](https://skmtc.dev/crevio/apis/crevio-api-v1/revisions/2219f18ad651?raw)
