---
title: "Set up placement daisy chaining"
type: reference
method: POST
path: /rest-api/placements/{placementId}/chaining.do
tag: "Placements"
---

# Set up placement daisy chaining

`POST https://YOUR-NETWORK-DOMAIN/rest-api/placements/{placementId}/chaining.do`

Switches daisy chaining (the ad waterfall) on or off for a placement and sets its options, as the console's Daisy Chaining card does. enabled=true (or a type) switches it on; type chooses whether the chain orders BANNERs or CAMPAIGNs; enabled=false switches it off and drops the chain. lookupDepth, viewPerEntityEnabled/viewPerEntityCount, rotatingEnabled/rotatingCount and groupByDeliveryPriority set the chain's options; only the ones sent change. The options need daisy chaining on - in the same request or before. Needs the Daisy Chaining permission and update rights on the placement's site.

## Path params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `placementId` | integer | yes | `4001` | Placement id |

## Form params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `enabled` | boolean | no | `true` | true switches daisy chaining on, false switches it off and drops the chain |
| `groupByDeliveryPriority` | boolean | no | `false` | Order the chain within each delivery priority |
| `lookupDepth` | integer | no | `5` | How many entries of the chain are tried for one ad request, 1 to 100 |
| `rotatingCount` | integer | no | `2` | Rotation count when rotatingEnabled, 1 to 10000000 |
| `rotatingEnabled` | boolean | no | `false` | Rotate the chain's entries |
| `type` | string | no | `CAMPAIGN` | What the chain orders: BANNER or CAMPAIGN; switches daisy chaining on |
| `viewPerEntityCount` | integer | no | `3` | Views per entry when viewPerEntityEnabled, 1 to 10000000 |
| `viewPerEntityEnabled` | boolean | no | `true` | Cap how many times each entry is shown before the next one |

## Responses

- `200` — {placementId, enabled, type, lookupDepth, viewPerEntityEnabled, viewPerEntityCount, rotatingEnabled, rotatingCount, groupByDeliveryPriority}
- `400` — Nothing sent, an option for a placement whose daisy chaining is off, enabled=false together with a type or an option, or a depth or count below 1
- `401` — Authentication error
- `403` — The Daisy Chaining permission is off, or no update rights on the placement's site
- `404` — The placement does not exist or is deleted

## Example request

```bash
curl --request POST \
  --url 'https://YOUR-NETWORK-DOMAIN/rest-api/placements/4001/chaining.do' \
  --header 'X-Api-Key: YOUR_API_KEY' \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data-urlencode 'type=CAMPAIGN' \
  --data-urlencode 'enabled=true' \
  --data-urlencode 'groupByDeliveryPriority=false'
```

Source: https://epom.com/ad-server/docs/api/placements/post-placements-chaining