---
title: "List ad units"
type: reference
method: GET
path: /rest-api/ad-units.do
tag: "Placements"
---

# List ad units

`GET https://YOUR-NETWORK-DOMAIN/rest-api/ad-units.do`

Returns the network's ad units - the sizes placements and banners are made in - with the placement types each one applies to. Use an id as adUnitId when creating or updating a placement or a banner. inventorySide marks a unit offered for placements, campaignsSide one offered for banners; custom marks the unit whose width and height are sent alongside it, anySize one that fits every size. Pass placementType to keep only the units of that type. With placementType, width and height the answer is the one unit a placement of that type and size is made in: the unit of exactly that size, or else the type's custom unit - or none when the type has neither.

## Query params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `placementType` | string | no | `SITE_PLACEMENT` | Keep only the ad units of this placement type |
| `width` | integer | no | `300` | With height and placementType: the width of the size to find the unit of, in pixels |
| `height` | integer | no | `250` | With width and placementType: the height of the size to find the unit of, in pixels |

## Responses

- `200` — [{id, name, width, height, custom, anySize, inventorySide, campaignsSide, placementTypes}]
- `400` — Unknown placementType, or width and height without placementType
- `401` — Authentication error
- `403` — Forbidden — insufficient permissions

## Example request

```bash
curl --request GET \
  --url 'https://YOUR-NETWORK-DOMAIN/rest-api/ad-units.do?placementType=SITE_PLACEMENT&width=300&height=250' \
  --header 'X-Api-Key: YOUR_API_KEY'
```

Source: https://epom.com/ad-server/docs/api/placements/get-ad-units