# Create ads

Coming soon: create a Display & Video 360 campaign, insertion order and line item with an existing creative in one call, paused unless you ask for it live.

Display & Video 360 is coming soon: it opens once Google verifies the permissions Zernio asks for. Until then only staff accounts can connect it.

## Create a campaign

`POST /v1/ads/create` on a `dv360ads` account builds a DV360 campaign, an insertion order and a line item, and assigns an existing creative to it.

```bash
curl -X POST "https://zernio.com/api/v1/ads/create" \
  -H "Authorization: Bearer $ZERNIO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "accountId": "ACCOUNT_ID",
    "adAccountId": "1234567",
    "name": "Spring launch",
    "goal": "awareness",
    "existingCreativeId": "987654321",
    "budgetAmount": 5000,
    "budgetType": "lifetime",
    "endDate": "2027-01-31T00:00:00Z",
    "countries": ["US"],
    "platformSpecificData": { "cpmBid": 4, "lineItemType": "display" }
  }'
```

`adAccountId` is the advertiser id. The budget is lifetime, and `platformSpecificData.cpmBid` is the line item's fixed CPM bid in whole currency units. `lineItemType` is `display` (the default) or `video`.

## How it behaves

- Nothing goes live unless you ask: the campaign stays paused and the insertion order and line item stay in draft, unless you send `status: "ACTIVE"`.
- `startDate` defaults to tomorrow in UTC, and `endDate` is required.
- `countries`, `languages`, `devices` and audiences go on the line item as its targeting.
- A step that fails after the DV360 campaign exists archives what was built.

## If it fails

| Error | Cause | Fix |
|-------|-------|-----|
| `422` naming `budget.type` | A daily budget | Send a lifetime budget. |
| `422` naming `platformSpecificData.cpmBid` | No CPM bid | Send `cpmBid` in whole currency units. |
| `422` naming `endDate` | No end date, or one before the start | Send an `endDate` after `startDate`. |

## Related

- [Create standalone ad](/ad-campaigns/create-standalone-ad)
- [Manage ads](/platforms/dv360/manage-ads)