Developer

Data deletion API

Submit a data deletion request over HTTP. DataCops emails the person a confirmation link, and only after they click it does it erase their data across your systems and connected platforms, within 30 days.

What it does

One POST creates a GDPR right-to-erasure (or CCPA) deletion request. To protect people, nothing is deleted until the requester confirms through a link sent to their own email. After they confirm, DataCops erases their personal data across its own systems and the platforms you have connected, and the request is completed within 30 days. For the product overview, see the data deletion page.

Submit a deletion request

POST /public/data-deletion/request

No private key is needed. Authenticate with your public cop_key in the body, so this can be called from the browser or your server. The response is identical whether or not DataCops holds data for that email, so it cannot be used to check who is in your system.

cURL
curl -X POST https://api.joindatacops.com/public/data-deletion/request \
  -H "Content-Type: application/json" \
  -d '{
    "email": "[email protected]",
    "cop_key": "YOUR_COP_KEY"
  }'
200 OK
{
  "success": true,
  "message": "Please check your email and click the link to confirm your deletion request."
}

DataCops emails the person a confirmation link. When they click it, the erasure runs and they receive a confirmation with a status link.

Check the status of a request

GET /public/dsar/proof/:code

Each request has a confirmation code (included in the status link the requester receives). This endpoint returns a sanitized, masked record so the requester, or you, can verify progress. It never returns raw personal data.

200 OK
{
  "status": "completed",
  "maskedEmail": "pe***@example.com",
  "received_at": "2026-08-28T01:00:00.000Z",
  "completed_at": "2026-08-28T01:02:00.000Z",
  "hard_purge_at": "2026-09-27T01:00:00.000Z",
  "session_records_anonymised": 3
}

The drop-in embed form

If you would rather not build the form yourself, drop this one tag on your privacy page and DataCops renders the request form inline, calling the endpoint above for you.

HTML
<script
  src="https://cdn.joindatacops.com/dsar-embed.js"
  data-cop-key="YOUR_COP_KEY"></script>

Errors

  • 200: request accepted (a confirmation email is sent).
  • 400: invalid email or missing/invalid cop_key.
  • 403: data deletion is not enabled for this site.
  • 500: unexpected error, retry.
Was this page helpful?