---
metadata:
  - name: generator
    content: Diplodoc Platform v5.52.0
alternate:
  - https://yandex.com/dev/direct/doc/en/curl-bids.md
  - https://yandex.com/dev/direct/doc/ru/curl-bids.md
  - href: en/curl-bids.md
    type: text/markdown
    title: Markdown version
  - href: llms.txt
    type: text/markdown
    title: llms.txt
sourcePath: en/examples/curl-bids.md
---
> **Documentation Index:** Fetch the complete configuration index at https://yandex.com/dev/direct/doc/en/llms.txt

# Setting bids

Uses the cURL utility

The example shows how to implement custom bid management using the [KeywordBids](https://yandex.com/dev/direct/doc/keywordbids/keywordbids.md).[setAuto](https://yandex.com/dev/direct/doc/keywordbids/setAuto.md) method. All keywords in the campaign are assigned a bid on search that is equal to the bid for the traffic volume of 75 plus 10%, which corresponds to premium impressions.

To use this example, specify the OAuth token and ID of the campaign where you are setting bids. If you're submitting a request on behalf of an agency, be sure to include the client's login.

```
curl \
  -H 'Authorization: Bearer TOKEN' \
  -H 'Client-Login: CLIENT_LOGIN' \
  -d '{ "method": "setAuto",
  "params": {
    "KeywordBids": [{
      "CampaignId": CAMPAIGN_ID,
      "BiddingRule": {
        "SearchByTrafficVolume": {
          "TargetTrafficVolume": 75,
          "IncreasePercent": 10
        }
      }
    }] 
  }
}' https://api.direct.yandex.com/json/v501/keywordbids
```

{% note info %}

For cURL in Windows, replace all single quotes with double quotes, and escape double quotes in JSON code. For example: `-d "{\"method\"`...

{% endnote %}
