add_negative_keywords
Set the complete list of negative keywords for Yandex Direct campaigns or ad groups, replacing any existing ones. Retrieve current list first, merge with new terms, then apply.
Instructions
Add negative (minus) keywords to campaigns or ad groups.
Sets the COMPLETE list of negative keywords — merges with existing ones. First call list_ad_groups or list_campaigns to get current NegativeKeywords, then include existing + new ones in your update.
Args: campaign_updates: List of campaign negative keyword updates: [{"Id": , "NegativeKeywords": {"Items": ["слово1", "слово2"]}}] ad_group_updates: List of ad group negative keyword updates: [{"Id": , "NegativeKeywords": {"Items": ["слово1", "слово2"]}}]
confirm: True to execute; False returns dry-run plan.IMPORTANT: This REPLACES the current negative keyword list for each object. To add incrementally: first read current list, merge, then update. SYNTAX: Negative keywords must NOT have the minus sign — just the word/phrase. E.g. Items: ["бесплатно", "своими руками", "скачать"]
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| campaign_updates | No | ||
| ad_group_updates | No | ||
| confirm | No |