Skip to main content
Users
CloudPortalLogin
  • Powered byPowered by
Developing with Sitecore CDP
Data privacy
Before you start sending data
Integrating with Sitecore CDP
Stream API
Batch API
REST APIs
Data lake export service
  • Sitecore CDP for developers
  • Batch API
  • Batch API Guest
  • Using guest delete

Using guest delete

The Guest Delete endpoint in the Sitecore CDP Batch API enables you to delete a guest record and all entities associated with the guest including orders, sessions, and events. This is an irreversible operation. After you delete a guest record, you cannot retrieve the guest record or any related entities.

The following steps provide an overview of how a guest is deleted:

  1. Upload a batch file containing guest records. If you are deleting the guest records in order to meet GDPR compliance, use gdpr_delete mode. If you are deleting the guest records for any other reason, use delete mode.

  2. If there is enough identifying information, proceed to the next step. If there is not enough identifying information, the Guest Delete endpoint returns a 400 Response Not Enough Identifying Info for the guest record.

  3. If the guest record is found, proceed to the next step. If the guest record is not found, the Guest Delete endpoint returns a 404 Response Guest not found.

  4. The Guest Delete endpoint attempts to find any and all Guests with matching identity:

    • The Guest Delete endpoint only finds one guest with matching identities. the Guest Delete endpoint returns a 200 Response Guest and associated entities deleted. The guest record is permanently deleted along with their sessions and events. Orders and order items are deleted only if you use the gdpr_delete mode, not if you use the delete mode. For more information, see how to delete order data in delete mode.

    • Alternatively, if the Guest Delete endpoint finds more than one guest with matching identities, the Guest Delete endpoint returns a 200 Response n matches found for this guest, 1st match deleted. In this 200 Response, n represents the number of guests with matching identities. Only the first guest with matching identities is deleted. You must perform this procedure again to delete any remaining guest records with matching identity.

Caution

Ensuring GDPR Compliance

If you are deleting a guest due to maintaining GDPR compliance, you must perform the above procedure for each matching identity. As the data controller, it is your responsibility to ensure that none of your systems send any of the deleted guest's PII to Sitecore CDP.

Do you have some feedback for us?

If you have suggestions for improving this article,

Privacy policySitecore Trust CenterCopyright © 1999-2026 Sitecore