Skip to main content
DELETE
/
group
/
{group_id}
Delete Group
curl --request DELETE \
  --url https://memory.stru.ai/group/{group_id} \
  --header 'X-API-Key: <x-api-key>'
{
  "message": "<string>"
}

Overview

Delete an entire group (user) and all associated data from the knowledge graph.
USE WITH EXTREME CAUTION! This permanently deletes ALL data for the user including:
  • All episodes
  • All facts
  • All entities
  • All relationships
This operation cannot be undone.

Authentication

X-API-Key
string
required
Your API key for authentication
X-API-Key: windowseat

Path Parameters

group_id
string
required
User identifier (group ID) to delete
/group/user_oauth_sub

Response

message
string
Confirmation message
"message": "Group deleted successfully"

Example Request

curl -X DELETE https://memory.stru.ai/group/user_oauth_sub \
  -H "X-API-Key: windowseat"

Example Response

{
  "message": "Group deleted successfully"
}

Use Cases

User Account Deletion

When a user deletes their account (GDPR compliance)

Complete Data Reset

Reset all data for a user during testing or development

Privacy Compliance

Fulfill data deletion requests per privacy regulations

Best Practices

Always confirm user intent before calling this endpoint - implement a confirmation dialog in your UI
Consider implementing a “soft delete” first - mark the account as deleted in your database before actually deleting from the knowledge graph
For deleting specific conversations, use DELETE /episodes/{group_id}/{source_description} instead