Skip to main content

Delete Memory

Delete a specific memory by its ID, or delete all memories for a project at once.

Delete a Single Memory​

Endpoint​

DELETE https://api.memory.audaxic.com/delete/{memory_id}

Path Parameters​

ParameterTypeDescription
memory_idstringID of the memory to delete

Response​

{
"success": true,
"deleted_count": 0
}
FieldTypeDescription
successbooleanAlways true on success
deleted_countintegerAlways 0 for single-delete (memory is deleted by ID directly)

Examples​

cURL:

curl -X DELETE https://api.memory.audaxic.com/delete/mem_abc123 \
-H "Authorization: Bearer ak_your_api_key"

JavaScript:

const response = await fetch("https://api.memory.audaxic.com/delete/mem_abc123", {
method: "DELETE",
headers: {
Authorization: "Bearer ak_your_api_key",
},
});

const data = await response.json();
console.log(data.deleted_count); // 0

Python:

import requests

response = requests.delete(
"https://api.memory.audaxic.com/delete/mem_abc123",
headers={"Authorization": "Bearer ak_your_api_key"},
)

data = response.json()
print(data["deleted_count"]) # 0

Delete All Memories for a Project​

Delete every memory associated with the project tied to the API key. Memories from other projects are not affected.

caution

This operation is irreversible. All memories for this project will be permanently removed.

Endpoint​

DELETE https://api.memory.audaxic.com/delete

Request Body​

No body required. Your project context is determined from the API key.

Response​

{
"success": true,
"deleted_count": 42
}
FieldTypeDescription
successbooleanAlways true on success
deleted_countintegerNumber of memories deleted

Examples​

cURL:

curl -X DELETE https://api.memory.audaxic.com/delete \
-H "Authorization: Bearer ak_your_api_key"

JavaScript:

const response = await fetch("https://api.memory.audaxic.com/delete", {
method: "DELETE",
headers: {
Authorization: "Bearer ak_your_api_key",
},
});

const data = await response.json();
console.log(data.deleted_count); // 42

Python:

import requests

response = requests.delete(
"https://api.memory.audaxic.com/delete",
headers={"Authorization": "Bearer ak_your_api_key"},
)

data = response.json()
print(data["deleted_count"]) # 42