# Method: advertisers.negativeKeywordLists.negativeKeywords.replace

> [!WARNING]
> Display \& Video 360 API v1 has been sunset.

- [HTTP request](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.HTTP_TEMPLATE)
- [Path parameters](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.PATH_PARAMETERS)
- [Request body](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.request_body)
  - [JSON representation](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.response_body)
  - [JSON representation](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.ReplaceNegativeKeywordsResponse.SCHEMA_REPRESENTATION)
- [Authorization Scopes](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.aspect)
- [Try it!](https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#try-it)

Replaces all negative keywords in a single negative keyword list.

The operation will replace the keywords in a negative keyword list with keywords provided in `https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords/replace#body.request_body.FIELDS.new_negative_keywords`.

### HTTP request

`POST https://displayvideo.googleapis.com/v1/advertisers/{advertiserId}/negativeKeywordLists/{negativeKeywordListId}/negativeKeywords:replace`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `advertiserId` | `string (https://developers.google.com/discovery/v1/type-format format)` Required. The ID of the DV360 advertiser to which the parent negative keyword list belongs. |
| `negativeKeywordListId` | `string (https://developers.google.com/discovery/v1/type-format format)` Required. The ID of the parent negative keyword list to which the negative keywords belong. |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "newNegativeKeywords": [ { object (`https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords#NegativeKeyword`) } ] } ``` |

| Fields ||
|---|---|
| `newNegativeKeywords[]` | ``object (`https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords#NegativeKeyword`)`` The negative keywords that will replace the existing keywords in the negative keyword list, specified as a list of `https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords#NegativeKeyword`. |

### Response body

If successful, the response body contains data with the following structure:
Response message for NegativeKeywordService.ReplaceNegativeKeywords.

| JSON representation |
|---|
| ``` { "negativeKeywords": [ { object (`https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords#NegativeKeyword`) } ] } ``` |

| Fields ||
|---|---|
| `negativeKeywords[]` | ``object (`https://developers.google.com/display-video/api/reference/rest/v1/advertisers.negativeKeywordLists.negativeKeywords#NegativeKeyword`)`` The full list of negative keywords now present in the negative keyword list. |

### Authorization Scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/display-video`

For more information, see the [OAuth 2.0 Overview](https://developers.google.com/identity/protocols/OAuth2).