---
title: "Delete Document"
method: DELETE
path: "/api/v3/documents/{document_id}"
tags: ["Documents"]
---

# Delete Document

`DELETE /api/v3/documents/{document_id}`

## Request

- Base URL: `https://api.nugen.in`
- URL: `https://api.nugen.in/api/v3/documents/{document_id}`
- Auth: HTTP bearer

Permanently delete a document.

This endpoint removes a document from the system. Note that this only deletes
the document record and metadata.

**Args**:
    `document_id`: Document ID to delete (path parameter)

**Returns**:
    `DocumentDeleteResponse`: Deletion confirmation containing:
        - `document_id`: ID of the deleted document
        - `message`: Success confirmation message

**Raises**:
    - `404`: If the document is not found or doesn't belong to the user

**Example**:
    **Request**:
    ```
        DELETE /api/v3/documents/document_01k4x9m2p7q3r5sa
        Headers: {"Authorization": "Bearer <api_key>"}
    ```
    **Response**:
    ```
        {
            "document_id": "document_01k4x9m2p7q3r5sa",
            "message": "Document Deleted Successfully"
        }
    ```

## Path parameters

- `document_id` string, required

## Response `200`

Returns a confirmation message with the ID of the deleted document. This endpoint permanently deletes the specified document from the system, including its metadata and any associated records. The response confirms the successful deletion by returning the document ID and a success message.

- DocumentDeleteResponse: Confirmation of a document deletion.
  - `document_id` string, required: document id
  - `message` string, required: Deletion Message

## Other responses

- `401`: Invalid API key
- `403`: Authorization header missing or not a Bearer token
- `404`: Resource not found
- `422`: Validation Error

---

[API](https://skmtc.dev/nugen/apis/nugen-intelligence-api.md) - [All operations](https://skmtc.dev/nugen/apis/nugen-intelligence-api/llms.txt) - [OpenAPI document](https://skmtc.dev/nugen/apis/nugen-intelligence-api/revisions/62baa7960a4a?raw)
