> ## Documentation Index
> Fetch the complete documentation index at: https://docs.shipstar.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Erase Recipients

> Permanently delete recipients — for when one of your users asks to be forgotten

Use this when a person asks you to erase their data (GDPR Article 17). Unlike a [removal](https://docs.shipstar.ai/api-reference/mailing-lists/remove-recipient.md), which keeps the row so the contact can be restored, an erase deletes the recipient outright — email, name, `external_id` and `attributes` — in any status.

One thing survives on purpose: if the person had **unsubscribed**, Shipstar keeps a one-way SHA-256 hash of their address on that list. A later [upsert](https://docs.shipstar.ai/api-reference/mailing-lists/upsert-recipients.md) or add of the same address is then still skipped as unsubscribed, so erasing someone can never quietly re-subscribe them. The hash can't be turned back into the address.

Up to 1000 identifiers per call; emails match case-insensitively. A repeated call reports everything as `not_found`.

## Authentication

This endpoint requires an API token passed as a Bearer token in the `Authorization` header.

```bash theme={null}
Authorization: Bearer YOUR_API_TOKEN
```

## Path Parameters

**list\_id** `string` *required*

The mailing list's unique identifier (UUID).

## Body

**emails** `string[]`

Email addresses to erase

**external\_ids** `string[]`

External ids to erase

At least one of the two, at most 1000 identifiers in total.

## Request

```bash cURL theme={null}
curl -X POST "https://api.shipstar.ai/api/v1/email/lists/a1b2c3d4-e5f6-7890-abcd-ef1234567890/recipients/erase" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"external_ids": ["usr_42"], "emails": ["former@example.com"]}'
```

## Response

**erased** `integer` *required*

Recipients permanently deleted

**suppressed** `integer` *required*

Of those, recipients who had unsubscribed — kept only as a hash so their opt-out holds

**not\_found** `string[]` *required*

Identifiers that matched nothing on this list

```json 200 theme={null}
{"erased": 2, "suppressed": 1, "not_found": []}
```

## Errors

| Status | Meaning |
| - | - |
| 401 | Missing or invalid API token |
| 404 | The list doesn't exist or belongs to another project |
| 422 | No identifiers, or more than 1000 |
| 429 | Rate limited (30 write calls per minute) |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.