---
search:
  tags:
    - Corpus
    - POST
seo:
  description: >-
    Redacts up to 100 records, keeping their order and ids. Records without an
    id are… Reference for the POST /v1/corpus/redact endpoint in the Webfold
    API.
sidebar:
  label: Redact a batch of records
  badge: POST
title: Redact a batch of records
type: openapi-operation
---
Redacts up to 100 records, keeping their order and ids. Records without an `id` are numbered `rec-<n>`. Each record is metered, as `corpus.redact`.

`POST /v1/corpus/redact`

**Request body** (`application/json`, required)

- `records` (CorpusRecord[], required)

Request body example:

```json
{
  "records": [
    {
      "id": "string",
      "text": "string"
    }
  ]
}
```

**Responses**

- `200` — Redacted records
- `400` — Bad request
- `401` — Missing or invalid bearer token
- `403` — Billing or plan entitlement blocked the request
- `502` — Upstream service (arXiv, YouTube, web page) failed
- `503` — The backing service is not configured or is busy

Response example, 200:

```json
{
  "records": [
    {
      "id": "string",
      "redacted_text": "string",
      "findings": [
        {
          "entity_type": "EMAIL",
          "start": 0,
          "end": 0,
          "score": 0
        }
      ]
    }
  ],
  "findings_total": 0
}
```
