---
title: "Delete a file"
method: DELETE
path: "/files/{assistant_name}/{assistant_file_id}"
tags: ["Manage Assistants"]
---

# Delete a file

`DELETE /files/{assistant_name}/{assistant_file_id}`

[Delete an uploaded file](https://docs.pinecone.io/guides/assistant/manage-files#delete-a-file) from an assistant.

This operation is asynchronous. The response includes an operation ID that can be used to poll for completion via the describe operation endpoint.

## Path parameters

- `assistant_name` string, required
- `assistant_file_id` string, required

## Headers

- `X-Pinecone-Api-Version` string, required

## Response `202`

The request to delete the file has been accepted. The deletion will be processed asynchronously.

- AssistantDataOperationModel — The OperationModel describes the status of an ongoing or completed server operation.
  - `id` string, required — The unique identifier for the operation.
  - `operation_type` string, required — The kind of action represented by this operation, such as uploading or deleting a file.
  - `file_id` string, nullable — The identifier of the file being operated on.
  - `status` string, required — The status of the operation. - `Processing`: The operation is in progress. - `Completed`: The operation finished successfully. - `Failed`: The operation failed. See `error_message` for details.
  - `created_on` string, date-time, required — The timestamp when the operation was created, in ISO 8601 format.
  - `completed_on` string, date-time, nullable — The timestamp when the operation completed or failed, in ISO 8601 format. Present only when status is `Completed` or `Failed`.
  - `percent_complete` integer — The progress made by the operation, as a percentage (0-100).
  - `error_message` string, nullable — A message describing the error that caused the operation to fail. Present only when status is `Failed`.
  - `ingestion_units` number, double, nullable — The number of ingestion units consumed by this operation. Present only when status is `Completed` for file ingestion operations.

## Other responses

- `204` — The file was deleted immediately. This occurs when deleting a file that previously failed processing.
- `401` — Unauthorized. Possible causes: Invalid API key.
- `404` — File not found.
- `500` — Internal server error.

---

[API](https://skmtc.net/pinecone/apis/pinecone-api.md) · [All operations](https://skmtc.net/pinecone/apis/pinecone-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/pinecone/pinecone-api/versions/35876583485d/schema)
