Delete data previously saved in the SDK.
This step is used to remove data that was previously stored on the client by the Save Data in SDK step. The data is stored in IndexedDB (Web), Keychain (iOS), or EncryptedSharedPreferences (Android), at the app (SDK instance) scope—not per journey.
You can delete selected keys or clear all saved data for the app. A deleted key is fully removed, not left as an empty value. After the step runs, subsequent journey invocations no longer return that data through @policy.sdkSavedData().
Storage failures do not abort the journey; enable journey event reporting if you need a failed delete to appear in Journey Analytics.
When this step and Save Data in SDK run in the same server response (no client-facing step between them), the SDK applies delete first, then save. Use that order when you need to drop previous session data and then persist a new value on the same round trip.
| Field | Description |
|---|---|
| Keys | Expression that yields an array of key names to remove (placeholder []). |
| Clear all | Removes all data saved in the SDK for this app. Clear all cannot be undone. |
This step can be configured to record step input and output data, or a custom payload, which is then surfaced in journey events in Journey Analytics for diagnostic purposes. For details, see Additional data reporting.
Use this step when stored client data should no longer be returned on the next journey call—for example, after logout.
If a login journey saved a session identifier and a user email with Save Data in SDK, a logout journey can delete only the session key and leave the email in place for the next login:
["session_id"]On the next journey invocation, @policy.sdkSavedData().session_id is no longer available, while @policy.sdkSavedData().userEmail still is.
To drop every stored key for the app, select Clear all instead.