---
title: "Exclude keywords from a Niche's Master Keyword List"
method: POST
path: "/v1/niches/{nicheId}/keyword-exclusions"
tags: ["v1"]
---

# Exclude keywords from a Niche's Master Keyword List

`POST /v1/niches/{nicheId}/keyword-exclusions`

## Request

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

Adds exact and phrase exclusions, the same way the web app does; the excluded keywords drop out of GET /v1/niches/{nicheId}/keywords at once. Only the exclusions change: every other Master Keyword List setting is kept.

Send 1 to 100 entries in total across `exact` and `phrase`. Entries already excluded are reported under `unchanged`, so repeating a call is safe. A Niche can have at most 1000 exclusions, exact and phrase combined. Free.

Rate limited to 30 requests per minute per Niche.

## Path parameters

- `nicheId` string, required

## Request body

- KeywordExclusionsRequestDto
  - `exact` string[]: Exact exclusions: each hides the one keyword that matches it exactly. At most 255 characters each. Entries are lower-cased and trimmed and must be unique after that; blank entries are ignored.
  - `phrase` string[]: Phrase exclusions: each hides every keyword that contains the phrase, as the web app does. At most 255 characters each. Entries are lower-cased and trimmed and must be unique after that; blank entries are ignored.

## Response `200`

- object
  - `message` string
  - `data` object
    - `exact` ExactKeywordExclusionDto[], required: Exact exclusions, oldest first.
      - `keyword` string, required
      - `searchVolume` number, required: Search volume of the excluded keyword. 0 when the Niche has no such keyword.
    - `phrase` PhraseKeywordExclusionDto[], required: Phrase exclusions, oldest first.
      - `phrase` string, required
      - `searchVolume` number, required: Total search volume of the keywords this phrase hides, besides those already excluded exactly.
      - `excludedKeywordsCount` number, required: Number of keywords this phrase hides.
    - `added` KeywordExclusionEntriesDto, required
      - `exact` string[], required
      - `phrase` string[], required
    - `unchanged` KeywordExclusionEntriesDto, required
      - `exact` string[], required
      - `phrase` string[], required

## Other responses

- `400`: Invalid nicheId or request body, or the add would take the Niche past 1000 exclusions. Nothing is saved.
- `401`: Api key is invalid
- `403`: The Niche belongs to another subscription
- `404`: Niche not found, or it has no completed research
- `429`: Rate limit exceeded (30 requests/min per organization and Niche).
- `500`: Internal error

## Changes

- **2026-10-13** `8ce2cc36c41a`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/datadive/apis/data-dive-developer-apis/changes/v1/niches/:nicheId/keyword-exclusions/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)
