Available in VPC
Delete a previously uploaded document. All indexing information associated with the document with the specified document ID is removed.
Request
This section describes the request format. The method and URI are as follows:
Method | URI |
---|---|
DELETE | /api/v1/svc/{serviceId}/doc/{docId} |
Request headers
For information about the headers common to all RAG APIs, see RAG request headers.
Request path parameters
The following describes the parameters.
Field | Type | Required | Description |
---|---|---|---|
serviceId |
String | Required | Service's unique identifier |
docId |
String | Required | Document'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}/doc/12345' \
--header 'Authorization: Bearer {apiKey}' \
--header 'Content-Type: application/json'
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 |
status.message |
String | - | API response status message |
result |
Object | - | Document 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.
Response example
The response example is as follows:
{
"status": {
"code": 200,
"message": ""
},
"result": {
"inserted": null,
"deleted": [
"12345"
],
"updated": null
}
}