---
title: "Delete File"
method: POST
path: "/v1/files/delete"
tags: ["Files"]
---

# Delete File

`POST /v1/files/delete`

## Request

- Base URL: `https://api.minimax.io`
- URL: `https://api.minimax.io/v1/files/delete`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/minimax/apis/minimax-api-2/docs/v1/files/delete/post.ts> (a function with typed inputs; its response is checked against the schema)

Delete a file by ID

## Query parameters

- `GroupId` string, required

## Request body

- DeleteFileReq
  - `file_id` integer, required: File ID to delete

## Response `200`

Successful response

- DeleteFileResp
  - `file_id` integer: Deleted file ID

## Other responses

- `400`: Bad request
- `401`: Unauthorized
- `404`: File not found
- `500`: Internal server error

---

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