---
title: "Set campaign weight on a placement"
type: reference
method: PUT
path: /rest-api/campaign/{campaignId}/placements/{placementId}/weight.do
tag: "Campaigns"
---

# Set campaign weight on a placement

`PUT https://YOUR-NETWORK-DOMAIN/rest-api/campaign/{campaignId}/placements/{placementId}/weight.do`

Gives the campaign its own weight on one placement that any of its banners is linked to, replacing its campaign weight in the campaign draw there: summer 3 against fall 1 sends three requests of four to the summer campaign on that placement only. 0 keeps the campaign out of the draw on that placement. House ads stay at 0 whatever is set. Requires UPDATE on the campaign's advertiser and the MANAGE_PLACEMENT_WEIGHTS and MANAGE_CAMPAIGN_WEIGHT permissions. Answers {success, campaignId, placementId, weight, effectiveWeight}; read it back with GET /rest-api/campaign/{campaignId}/placements/weights.do.

## Path params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `campaignId` | integer | yes | `12` | Unique identifier of the campaign |
| `placementId` | integer | yes | `3001` | Placement any of the campaign's banners is linked to |

## Form params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `weight` | integer | yes | `3` | The campaign's weight on this placement, a whole number from 0 to 32767 |

## Responses

- `200` — The weight was set
- `400` — The weight is outside 0-32767
- `401` — Authentication error
- `403` — Insufficient permissions, naming the missing one
- `404` — The campaign does not exist, or none of its banners is linked to the placement

## Example request

```bash
curl --request PUT \
  --url 'https://YOUR-NETWORK-DOMAIN/rest-api/campaign/12/placements/3001/weight.do' \
  --header 'X-Api-Key: YOUR_API_KEY' \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data-urlencode 'weight=3'
```

Source: https://epom.com/ad-server/docs/api/campaigns/put-campaign-placements-weight