---
title: "Add campaign competitors"
type: reference
method: POST
path: /rest-api/campaign/{campaignId}/competitors/add.do
tag: "Campaigns"
---

# Add campaign competitors

`POST https://YOUR-NETWORK-DOMAIN/rest-api/campaign/{campaignId}/competitors/add.do`

Links the given campaigns to this one as competitors, both ways, the way the console's Competitors card does: each linked competitor has its own competitor separation switched on. The campaign's separation must already be on (see competitors/enable). Ids that do not exist are listed in notFound, campaigns the caller may not manage in accessForbidden; they are left alone. Answers the resulting competitor list, as the list endpoint does. Requires the COMPETITOR_CAMPAIGNS permission and UPDATE access to the advertisers of both campaigns.

## Path params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `campaignId` | integer | yes | `2001` | Unique identifier of the campaign |

## Form params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `competitorIds` | array<integer> | yes | `2002` | IDs of the competitor campaigns — repeat the parameter or separate with commas |

## Responses

- `200` — Competitors linked; competitors lists the campaign's competitors afterwards
- `400` — Competitor separation is off for the campaign, or no competitorIds
- `401` — Authentication error
- `403` — Not enough permissions on the campaign
- `404` — Campaign not found or deleted

## Example request

```bash
curl --request POST \
  --url 'https://YOUR-NETWORK-DOMAIN/rest-api/campaign/2001/competitors/add.do' \
  --header 'X-Api-Key: YOUR_API_KEY' \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data-urlencode 'competitorIds=2002'
```

Source: https://epom.com/ad-server/docs/api/campaigns/post-campaign-competitors-add