Clear a Session
DELETE
/api/v1/conversations/{session_id}Permanently deletes all messages in the given session. The next message sent with the same session_id starts a fresh conversation.
Required scope: write
This operation is irreversible. All messages in the session are permanently deleted.
Path parameters
session_idstringpathrequiredThe session to clear.
Response
successbooleanAlways
true.session_idstringThe session that was cleared.
deletedbooleanAlways
true.Example
curl -X DELETE \
"https://api.personaliai.com/api/v1/conversations/visitor-xyz-789" \
-H "Authorization: Bearer chatty_sk_your_key"200 OK:
{ "success": true, "session_id": "visitor-xyz-789", "deleted": true }Use cases
- GDPR / privacy — delete a specific user's conversation history on request
- Demo resets — clear a test session between automated runs
- Fresh start — allow a visitor to restart their conversation