# Bulk Untag Leads

> Remove tags from many leads at once.

Requires an API key with the `write` scope.

Up to 1,000 selected leads run inside the request and the job comes back `completed` (`200`). More than that is queued: the response is `202` with a `pending` job; poll [Get Job](/api-reference/jobs/get-job) until it is `completed`.

Tags that a lead does not carry are ignored. The tags themselves are kept.

## Body Parameters

<ParamField body="leadIds" type="string[]">Lead IDs, up to 50,000. Send this or `filter`, not both.</ParamField>
<ParamField body="filter" type="object">Select leads by filter instead. Keys: `search`, `status`, `tags` (comma separated; a lead must carry all of them), `provider`, `interestStatus`, `labelId`. Matches at most 50,000 leads, newest first.</ParamField>
<ParamField body="tags" type="string[]" required>Tag names to remove, 1 to 50.</ParamField>

## Response

<ResponseField name="data" type="object">
  The job. See [Get Job](/api-reference/jobs/get-job) for every field.

  <Expandable title="Job object">
    <ResponseField name="id" type="string">Job identifier.</ResponseField>
    <ResponseField name="type" type="string">`lead_bulk`.</ResponseField>
    <ResponseField name="status" type="string">`completed` when the call finished the work (200), `pending` when it was queued (202).</ResponseField>
    <ResponseField name="totalItems" type="integer">Leads selected.</ResponseField>
    <ResponseField name="result" type="object">`{ "updated": 120 }`: how many of the selected leads in your workspace were processed.</ResponseField>
  </Expandable>
</ResponseField>

<RequestExample>
```bash cURL
curl -X POST "https://api.foxreach.io/api/v1/leads/bulk/untag" \
  -H "X-API-Key: otr_your_key" \
  -H "Content-Type: application/json" \
  -d '{"leadIds": ["cmlead1"], "tags": ["acme"]}'
```

```python Python SDK
from foxreach import FoxReach

client = FoxReach(api_key="otr_your_key")
job = client.leads.bulk_untag(["acme"], lead_ids=["cmlead1"])
```

```typescript TypeScript SDK
import { FoxReach } from "foxreach";

const client = new FoxReach({ apiKey: "otr_your_key" });
const job = await client.leads.bulkUntag({ tags: ["acme"], leadIds: ["cmlead1"] });
```
</RequestExample>

<ResponseExample>
```json
{
  "data": {
    "id": "cmjob902",
    "type": "lead_bulk",
    "status": "completed",
    "progress": 100,
    "totalItems": 1,
    "completedItems": 1,
    "result": { "updated": 1 },
    "error": null,
    "startedAt": "2026-11-04T09:00:00",
    "completedAt": "2026-11-04T09:00:00",
    "createdAt": "2026-11-04T09:00:00"
  }
}
```
</ResponseExample>

## Errors

| Status | Description |
|--------|-------------|
| `401` | Missing, invalid, revoked or expired API key |
| `403` | API key does not have the required scope: `write` |
| `422` | Neither or both of `leadIds` and `filter` were sent, or `tags` is empty |

## Rate Limit

- **100 requests per minute, shared by every `bulk` call in your workspace.** Fixed 60-second window.
- Every response includes `X-RateLimit-Limit`, `X-RateLimit-Remaining`, `X-RateLimit-Reset` (unix epoch seconds) and `X-RateLimit-Bucket` (`bulk`).
- A `429` response includes a `Retry-After` header (seconds until the bucket resets).

For client-side patterns (`Retry-After`, exponential backoff, monitoring `X-RateLimit-Remaining`), see [Rate Limiting](/rate-limiting).
