Skip to main content
clear_user() removes every cache entry whose user scope matches user_id, leaving other users’ cached data untouched. Pair this with the durable memory deletion APIs to honor right-to-be-forgotten requests end-to-end: this call handles the SDK’s local cache, while platform-side deletion ensures the user’s stored memories are removed from Synap itself. This is a synchronous method, no await.

Parameters

string
required
The external user identifier whose cached data should be dropped. Must match the user_id you originally passed to fetch(), memories.create(), or other scope-aware calls.

Returns

Returns None.

Example

Raises

This method does not raise SDK errors. See Error Codes for the full SDK exception hierarchy.

See also