---
title: "Remove labels from a Niche"
method: POST
path: "/v1/niches/{nicheId}/labels/remove"
tags: ["v1"]
---

# Remove labels from a Niche

`POST /v1/niches/{nicheId}/labels/remove`

## Request

- Base URL: `https://api.datadive.tools`
- URL: `https://api.datadive.tools/v1/niches/{nicheId}/labels/remove`
- Auth: API key in header `x-api-key`

Takes the Niche out of the given labels, from GET /v1/labels. A delta: labels you do not list are left as they are, and so are assignee tags. Ids already detached are counted in `removed` / `notPresent`, never errors.

All or nothing: if any id is not a label of your organization the call fails with 404 and `unknownIds`, and nothing changes. The acting member needs Manage access to the Niche; `x-api-key` calls act as the owner.

Rate limited to 2 requests per minute per Niche.

## Path parameters

- `nicheId` string, required

## Request body

- NicheLabelsRequestDto
  - `labelIds` number[], required: Ids of the labels to change, from GET /v1/labels. 1-100, unique.

## Response `200`

- object
  - `message` string
  - `data` object
    - `removed` number, required: Detached from the Niche
    - `notPresent` number, required: Not attached to the Niche. Left untouched, not an error.

## Other responses

- `400`: Invalid nicheId or request body
- `401`: Api key is invalid
- `403`: The acting member cannot manage the Niche, or the Niche belongs to another subscription
- `404`: Niche not found, or ids that are not labels of your organization (`unknownIds`)
- `429`: Rate limit exceeded (2 requests/min per organization and Niche).
- `500`: Internal error

## Changes

- **2026-11-02** `94c025cac171`: 1 breaking
  - removed the media type `application/json` for the response with the status `403`
- **2026-10-26** `838b9910d190`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/datadive/apis/data-dive-developer-apis/changes/v1/niches/:nicheId/labels/remove/post.md)

---

[API](https://skmtc.dev/datadive/apis/data-dive-developer-apis.md) - [All operations](https://skmtc.dev/datadive/apis/data-dive-developer-apis/llms.txt) - [OpenAPI document](https://skmtc.dev/datadive/apis/data-dive-developer-apis/revisions/94c025cac171?raw)
