--- title: "Delete file" slug: "rag-delete-file" updated: 2026-09-17T09:35:51Z published: 2026-09-17T09:35:51Z canonical: "api.ncloud-docs.com/rag-delete-file" --- > ## Documentation Index > Fetch the complete documentation index at: https://api.ncloud-docs.com/llms.txt > Use this file to discover all available pages before exploring further. # Delete file Available in VPC Delete a previously uploaded file. All indexing information associated with the document with the specified file ID is removed. ## Request This section describes the request format. The method and URI are as follows: | Method | URI | | --- | --- | | DELETE | /api/v1/svc/{serviceId}/file/{fileId} | ### Request headers For information about the headers common to all RAG APIs, see [RAG request headers](/docs/en/rag-overview#%EC%9A%94%EC%B2%AD%ED%97%A4%EB%8D%94). ### Request path parameters You can use the following path parameters with your request: | Field | Type | Required | Description | | --- | --- | --- | --- | | `serviceId` | String | Required | Service's unique identifier | | `fileId` | String | Required | File's unique identifier | ### Request example The request example is as follows: ``` curl --location --request DELETE 'https://kr-pub-gateway.rag.naverncp.com/api/v1/svc/{serviceId}/file/12345' \ --header 'Authorization: Bearer {apiKey}' ``` ## Response This section describes the response format. ### Response body The response body includes the following data: | Field | Type | Required | Description | | --- | --- | --- | --- | | `status` | Object | - | API processing result | | `status.code` | Integer | - | [API response status code](/docs/en/rag-overview#%EC%9D%91%EB%8B%B5%EC%83%81%ED%83%9C%EC%BD%94%EB%93%9C) | | `status.message` | String | - | [API response status message](/docs/en/rag-overview#%EC%9D%91%EB%8B%B5%EC%83%81%ED%83%9C%EC%BD%94%EB%93%9C) | | `result` | Object | - | File processing result | | `result.inserted` | Array | - | Created file ID (always `null`) | | `result.deleted` | Array | - | Deleted file ID | | `result.updated` | Array | - | Edited file ID (always `null`) | ### Response status codes For information about the HTTP status codes common to all RAG APIs, see [RAG response status codes](/docs/en/rag-overview#%EC%9D%91%EB%8B%B5%EC%83%81%ED%83%9C%EC%BD%94%EB%93%9C). ### Response example The response example is as follows: ``` { "status": { "code": 200, "message": "" }, "result": { "inserted": null, "deleted": [ "12345" ], "updated": null } } ```