---
title: "Purge Visitors"
method: POST
path: "/v2/purge/visitors"
tags: ["V2"]
---

# Purge Visitors

`POST /v2/purge/visitors`

The Purge Visitors API helps teams comply with end-user bulk data deletion requests mandated by laws like GDPR and CCPA. This endpoint will delete users and all related user data identified by a set of emails, visitor IDs, or user IDs.

Purge requests default to being processed 10 days after submission, however this delay can be configured via the delaySeconds parameter. The endpoint is limited to 100 visitor deletions per request.

One of email, userId, or visitorId parameter is required to identify the user for data deletion.

## Headers

- `Authorization` string, required

## Request body

- object
  - `delaySeconds` integer — Seconds to wait before starting visitor data purging. This can be used as a safety measure in case the request needs to be canceled.
  - `emails` string[] — List of emails for which visitor data will be purged.
  - `userIds` string[] — List of user IDs (external user IDs) for which visitor data will be purged.
  - `visitorIds` string[] — List of visitor IDs for which visitor data will be purged.

## Response `200`

OK

- object
  - `requestId` string

## Other responses

- `400` — Bad Request
- `403` — You may have an invalid or missing API key and you should check your authorization header. There is no message with this status code.
- `404` — Not Found
- `429` — Your application has made too many requests in too short a time.
- `500` — Something went wrong on Sprig's side. These are very rare :)

---

[API](https://skmtc.dev/sprig/apis/sprig-api.md) · [All operations](https://skmtc.dev/sprig/apis/sprig-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/sprig/sprig-api/revisions/e415b6f55281/schema)
