---
title: "Delete a file"
method: DELETE
path: "/v1/files/{file_id}"
tags: ["files"]
---

# Delete a file

`DELETE /v1/files/{file_id}`

## Request

- Base URL: `https://api.niubai.vip` (the document declares no server; this is the origin it was published from)
- URL: `https://api.niubai.vip/v1/files/{file_id}`
- Auth: HTTP bearer

Remove an uploaded or produced document before its 24-hour retention ends, together with the outputs and previews derived from it. Owner only.

## Path parameters

- `file_id` string, required

## Response `204`

Successful Response

## Other responses

- `401`: error.code is one of: unauthorized
- `404`: error.code is one of: not_found
- `429`: error.code is one of: rate_limited

---

[API](https://skmtc.dev/niubai/apis/pdf-edit-api-gateway.md) · [All operations](https://skmtc.dev/niubai/apis/pdf-edit-api-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/niubai/apis/pdf-edit-api-gateway/revisions/1ad0ce16ca04?raw)
