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

# Redact a customer

> Permanently remove personal information from a customer while keeping invoices, tenancies, and other records intact.

A **redaction** wipes personally identifiable information from a customer and any copies of that information on related records. Object IDs, amounts, dates, statuses, and relationships stay in place so billing and leasing history remains usable.

Use redaction when you need to honour a data-erasure request without deleting the customer's financial or tenancy trail. To remove the customer record itself, [delete the customer](/api/core/customers/delete) instead.

<Warning>
  Redaction cannot be undone. After it starts, the customer cannot be edited or deleted.
</Warning>

<Note>
  Only account **admins** can create a redaction. The option is hidden from every other role in the Dashboard, and the API rejects non-admin session users.
</Note>

## Redact from the Dashboard

1. Open the [customer](https://dashboard.yorlet.com/customers) you want to redact.
2. Open the **Actions** menu and select **Redact personal information**.
3. Review what will be removed, then click **Redact customer**.

The customer shows a **Redacting** badge while the wipe runs in the background, then **Redacted** when it finishes. Edit is hidden once redaction has started.

## What is removed

Personal information is replaced with a placeholder (`[redacted]`, `{id}@redacted.invalid`, or `null`) on:

* The **customer** — name, email, phone, address, description, legal name and date of birth, invoicing emails, metadata, and stored previous addresses. The customer is also archived.
* **Invoices** — copied customer name, email, phone, and address.
* **Applications** and **tenancies** — that customer's name and email in the shared customer snapshot.
* **Payment methods** — billing name, email, phone, and address. Last4, brand, and mandate references are kept.
* **Verification sessions and reports** — provided identity details, date of birth, share codes, and previous addresses.
* The linked **Stripe customer** — name, email, phone, and address are updated. The Stripe customer is not deleted.

Country on an address is kept so tax and reporting context remains.

## What is kept

These are not wiped:

* Object IDs and creation timestamps
* Relationships (the customer ID on invoices, tenancies, applications, and payments)
* Amounts, dates, statuses, and invoice prefixes
* Payment method last4, brand, and mandate references

## After a redaction

* `customer.redaction` is `{ "status": "processing" }` while the job runs, then `{ "status": "redacted" }`.
* Updates and deletes on that customer return an error.
* Creating the same redaction again is idempotent: a processing or completed redaction is returned as-is. A failed redaction is retried.

Listen for [`redaction.created`](/api/events#redaction-created), [`redaction.redacted`](/api/events#redaction-redacted), and [`redaction.failed`](/api/events#redaction-failed) on your [webhook endpoints](/development/webhooks).

## Redact with the API

Create a redaction with [`POST /v1/redactions`](/api/core/redactions/create). Session users must be admins. Restricted secret keys need the `admin` or `redactions.write` permission.

```bash theme={"theme":"dracula"}
curl https://api.yorlet.com/v1/redactions \
  -u sk_test_xxx: \
  -d customer=cus_xxx
```

The response is a [redaction object](/api/core/redactions/object) with `status` of `processing`. Poll [`GET /v1/redactions/:id`](/api/core/redactions/retrieve) or wait for `redaction.redacted`.

The `redaction` field on the [customer object](/api/core/customers/object) is available from API version `2026-09-14`. See the [API changelog](/development/api-changelog).
