# Creative API

### Creatives

The images, banners, video, audio that are displayed as ads.

### List creatives

```
GET /v1/creatives/advar
```

Get a list of advar creatives filtered on at least one parameter.

**Request body**

<table id="bkmrk-parameter-in-require" style="border-collapse: collapse; width: 100%; height: 287.8px;"><thead><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;">**Parameter**</td><td style="width: 11.7985%; height: 29.8px;">**In**</td><td style="width: 9.89401%; height: 29.8px;">**Required**</td><td style="width: 9.29678%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>creativeId</code></td><td style="width: 11.7985%; height: 29.8px;">path</td><td style="width: 9.89401%; height: 29.8px;">Yes</td><td style="width: 9.29678%; height: 29.8px;">integer</td><td style="width: 50.7747%; height: 29.8px;">The creatives ID.</td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>campaignId</code></td><td style="width: 11.7985%; height: 46.6px;">parameter</td><td style="width: 9.89401%; height: 46.6px;">No</td><td style="width: 9.29678%; height: 46.6px;">integer</td><td style="width: 50.7747%; height: 46.6px;">Campaign ID of the campaign whose advar creatives you want to list.</td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>creativeId</code></td><td style="width: 11.7985%; height: 29.8px;">parameter</td><td style="width: 9.89401%; height: 29.8px;">No</td><td style="width: 9.29678%; height: 29.8px;">integer</td><td style="width: 50.7747%; height: 29.8px;">Comma separated list of creative ids you want to list.</td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>bookingId</code></td><td style="width: 11.7985%; height: 46.6px;">parameter</td><td style="width: 9.89401%; height: 46.6px;">No</td><td style="width: 9.29678%; height: 46.6px;">integer</td><td style="width: 50.7747%; height: 46.6px;">Comma separated list of booking ids you want to list creatives for.</td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>search</code></td><td style="width: 11.7985%; height: 46.6px;">parameter</td><td style="width: 9.89401%; height: 46.6px;">No</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">An url-encoded search string to apply to the list of creatives (ignoring case, on creative name).</td></tr><tr style="height: 28.8px;"><td style="width: 18.236%; height: 28.8px;"><code>limit</code></td><td style="width: 11.7985%; height: 28.8px;">parameter</td><td style="width: 9.89401%; height: 28.8px;">No</td><td style="width: 9.29678%; height: 28.8px;">integer</td><td style="width: 50.7747%; height: 28.8px;">Pagination property to limit the number of returned targets.</td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>offset</code></td><td style="width: 11.7985%; height: 29.8px;">parameter</td><td style="width: 9.89401%; height: 29.8px;">No</td><td style="width: 9.29678%; height: 29.8px;">integer</td><td style="width: 50.7747%; height: 29.8px;">Pagination property to offset the returned targets.</td></tr></tbody></table>

**Response** - 200

```
[
    {
        "creativeId": 18,
        "campaignId": 17,
        "creativeName": "27M2N8500/01 Rectangle 1",
        "formatId": 1,
        "advarTemplateName": "Image_FlexBanner.html",
        "sku": null,
        "lastEditedDate": "2026-07-01T10:16:32Z",
        "templateParameters": {
            "<CLICKURL>": "https://www.philips.be/c-p/27M2N8500_01/gamemonitor-qd-oled-gamemonitor",
            "<ALT_TEXT>": "QD OLED-gamemonitor"
        },
        "templateFiles": {
            "2": {
                "fileName": null,
                "filePath": "https://demo-preview.adhese.org/pool/lib/18_2nd_1.png"
            }
        },
        "lastEdited": 1782900992000
    },
    {
        "creativeId": 19,
        "campaignId": 17,
        "creativeName": "27M2N8500/01 Rectangle 2",
        "formatId": 1,
        "advarTemplateName": "Image_FlexBanner.html",
        "sku": null,
        "lastEditedDate": "2026-07-01T10:19:06Z",
        "templateParameters": {
            "<CLICKURL>": "https://www.philips.be/c-p/27M2N8500_01/gamemonitor-qd-oled-gamemonitor",
            "<ALT_TEXT>": "QD OLED-gamemonitor 2"
        },
        "templateFiles": {
            "2": {
                "fileName": null,
                "filePath": "https://demo-preview.adhese.org/pool/lib/19_2nd_1.png"
            }
        },
        "lastEdited": 1782901146000
    },
    {
        "creativeId": 27,
        "campaignId": 17,
        "creativeName": "Apitest advar banner ",
        "formatId": 1,
        "advarTemplateName": "Image_FlexBanner.html",
        "sku": "",
        "lastEditedDate": "2026-08-10T07:29:49Z",
        "templateParameters": {
            "<CLICKURL>": "",
            "<ALT_TEXT>": ""
        },
        "templateFiles": {
            "2": {
                "fileName": null,
                "filePath": "https://demo-preview.adhese.org/pool/lib/27_2nd_1.png"
            }
        },
        "lastEdited": 1786346989000
    }
]
```

**Response codes**

<table id="bkmrk-status-meaning-201-c" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3133%;"></col><col style="width: 85.6847%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>200</code></td><td style="height: 29.8px;">Creatives found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr><td><code>409</code></td><td>Conflict.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### Update an advar creative

```
PUT /v1/creatives/advar/{creativeId}
```

Updates an advar creative by creative ID

**Request body**

<table id="bkmrk-parameter-in-require-1" style="border-collapse: collapse; width: 100%; height: 59.6px;"><thead><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;">**Parameter**</td><td style="width: 8.46246%; height: 29.8px;">**In**</td><td style="width: 10.1311%; height: 29.8px;">**Required**</td><td style="width: 12.3957%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>creativeId</code></td><td style="width: 8.46246%; height: 29.8px;">path</td><td style="width: 10.1311%; height: 29.8px;">Yes</td><td style="width: 12.3957%; height: 29.8px;">integer</td><td style="width: 50.7747%; height: 29.8px;">The creatives ID.</td></tr></tbody></table>

**Updating an advar creative**

```
{
  "campaignId": 17,
  "creativeName": "Apitest advar banner update",
  "sku": "string",
  "formatId": 1,
  "advarTemplateName": "Image_FlexBanner.html",
  "templateParameters": {},
  "templateFiles": {}
}
```

**Response** - 200

```
{
    "creativeId": 27,
    "campaignId": 17,
    "creativeName": "Apitest advar banner update",
    "formatId": 1,
    "advarTemplateName": "Image_FlexBanner.html",
    "sku": "string",
    "lastEditedDate": "2026-08-10T13:36:10Z",
    "templateParameters": {},
    "templateFiles": {
        "2": {
            "fileName": null,
            "filePath": "https://demo-preview.adhese.org/pool/lib/27_2nd_1.png"
        }
    },
    "lastEdited": 1786368970000
}
```

**Response codes**

<table id="bkmrk-status-meaning-200-c" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3133%;"></col><col style="width: 85.6847%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>200</code></td><td style="height: 29.8px;">Creative updated.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### List a single creative

```
GET /v1/creatives/advar/{id}
```

Returns a single creatives' details by creative ID

**Request body**

<table id="bkmrk-parameter-in-require-2" style="border-collapse: collapse; width: 100%; height: 59.4px;"><thead><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;">**Parameter**</td><td style="width: 11.7985%; height: 29.8px;">**In**</td><td style="width: 9.89401%; height: 29.8px;">**Required**</td><td style="width: 9.29678%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 29.6px;"><td style="width: 18.236%; height: 29.6px;"><code>id</code></td><td style="width: 11.7985%; height: 29.6px;">path</td><td style="width: 9.89401%; height: 29.6px;">Yes</td><td style="width: 9.29678%; height: 29.6px;">string</td><td style="width: 50.7747%; height: 29.6px;">Id of the creative you want to return</td></tr></tbody></table>

**Response** - 200

```
{
    "creativeId": 30,
    "campaignId": 27,
    "creativeName": "Copy of Apitestpotmancreative",
    "formatId": 1,
    "advarTemplateName": "Image_FlexBanner.html",
    "sku": null,
    "lastEditedDate": "2026-09-08T08:00:13Z",
    "templateParameters": {
        "<CLICKURL>": "https://example.com",
        "<ALT_TEXT>": "My creative alt text"
    },
    "templateFiles": {
        "2": {
            "fileName": null,
            "filePath": "https://demo.preview.adhese.eu/pool/lib/30_2nd_1.jpg"
        }
    },
    "readonly": false,
    "lastEdited": 1788854413000
}
```

**Response codes**

<table id="bkmrk-status-meaning-200-c-1" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3133%;"></col><col style="width: 85.6847%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>200</code></td><td style="height: 29.8px;">Creative updated.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### List the preview links of a single creative

```
GET /v1/creatives/advar/{id}/preview-links
```

Lists the preview links associated with the requested creative.

<table id="bkmrk-parameter-in-require-3" style="border-collapse: collapse; width: 100%; height: 59.6px;"><thead><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;">**Parameter**</td><td style="width: 8.46246%; height: 29.8px;">**In**</td><td style="width: 10.1311%; height: 29.8px;">**Required**</td><td style="width: 12.3957%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>creativeId</code></td><td style="width: 8.46246%; height: 29.8px;">path</td><td style="width: 10.1311%; height: 29.8px;">Yes</td><td style="width: 12.3957%; height: 29.8px;">integer</td><td style="width: 50.7747%; height: 29.8px;">The creatives ID.</td></tr></tbody></table>

**Response** - 200

```
[
    "https://adhese.eu?adhesePreviewCreativeId=22:e0c0a655-3f46-4231-850c-acfa0ed976de&adhesePreviewSlotId=14&adhesePreviewWidth=16&adhesePreviewHeight=9&adhesePreviewTemplateFile=preview.html&adhesePreviewCreativeKey&adhesePreviewCreativeTemplate=landscape"
]
```

**Response codes**

<table id="bkmrk-status-meaning-200-c-2" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3133%;"></col><col style="width: 85.6847%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>200</code></td><td style="height: 29.8px;">Preview links retrieved.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### Upload a creative file

```
POST /v1/creatives/file
```

Uploads a creative file to temporary storage to use when uploading an advar creative.

**Request body**

<table id="bkmrk-parameter-in-require-4" style="border-collapse: collapse; width: 100%; height: 292.6px;"><thead><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;">**Parameter**</td><td style="width: 11.7985%; height: 29.8px;">**In**</td><td style="width: 9.89401%; height: 29.8px;">**Required**</td><td style="width: 9.29678%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>Content&#45;Disposition</code></td><td style="width: 11.7985%; height: 46.6px;">header</td><td style="width: 9.89401%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">Contains the file name and is filled in accordingly <code>attachment&#59; filename&#61;filename&#46;extension</code></td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>Use&#45;Keycloak&#45;Auth</code></td><td style="width: 11.7985%; height: 29.8px;">header</td><td style="width: 9.89401%; height: 29.8px;">Yes</td><td style="width: 9.29678%; height: 29.8px;">boolean</td><td style="width: 50.7747%; height: 29.8px;">Default is <code>true</code></td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>Content&#45;Type</code></td><td style="width: 11.7985%; height: 29.8px;">header</td><td style="width: 9.89401%; height: 29.8px;">Yes</td><td style="width: 9.29678%; height: 29.8px;">string</td><td style="width: 50.7747%; height: 29.8px;"><code>application&#47;octet&#45;stream</code></td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>formatId</code></td><td style="width: 11.7985%; height: 46.6px;">parameter</td><td style="width: 9.89401%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">The ID of the format that will be associated with the creative.</td></tr><tr style="height: 63.4px;"><td style="width: 18.236%; height: 63.4px;"><code>key</code></td><td style="width: 11.7985%; height: 63.4px;">parameter</td><td style="width: 9.89401%; height: 63.4px;">No</td><td style="width: 9.29678%; height: 63.4px;">string</td><td style="width: 50.7747%; height: 63.4px;">Creative file index written as ordinal number (e.g. 2nd) with the exception of 1, which has key "main" (but is not used in advar creatives). Default value is <code>main</code></td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>File contents</code></td><td style="width: 11.7985%; height: 46.6px;">body</td><td style="width: 9.89401%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">binary data</td><td style="width: 50.7747%; height: 46.6px;">File contents as binary data to be uploaded to temporary storage.</td></tr></tbody></table>

**Response** - 201

```
{
    "filePath": "/home/adhese/www/docker.adhese.org/tmp/file_by_user_1_9072608199649672610.jpg"
}
```

**Response codes**

<table id="bkmrk-status-meaning-201-f" style="border-collapse: collapse; width: 100%; height: 238.4px;"><colgroup><col style="width: 14.3133%;"></col><col style="width: 85.6847%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>201</code></td><td style="height: 29.8px;">File uploaded successfully.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr><td><code>415</code></td><td>Unsupported Media Type.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>422</code></td><td style="height: 29.8px;">Unprocessable entity.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### Create an advar creative

```
POST /v1/creatives/advar
```

Creates an advar creative under the chosen campaign.

**Request body**

<table id="bkmrk-parameter-in-require-5" style="border-collapse: collapse; width: 100%; height: 495.8px;"><thead><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;">**Parameter**</td><td style="width: 11.7985%; height: 29.8px;">**In**</td><td style="width: 9.89401%; height: 29.8px;">**Required**</td><td style="width: 9.29678%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>campaignId</code></td><td style="width: 11.7985%; height: 46.6px;">body</td><td style="width: 9.89401%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">Id of the campaign under wich you want to create a creative.</td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>creativeName</code></td><td style="width: 11.7985%; height: 46.6px;">body</td><td style="width: 9.89401%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">The ID of the format that will be associated with the creative.</td></tr><tr style="height: 63.4px;"><td style="width: 18.236%; height: 63.4px;"><code>sku</code></td><td style="width: 11.7985%; height: 63.4px;">body</td><td style="width: 9.89401%; height: 63.4px;">No</td><td style="width: 9.29678%; height: 63.4px;">string</td><td style="width: 50.7747%; height: 63.4px;">SKU of the product related to the product.</td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>formatId</code></td><td style="width: 11.7985%; height: 46.6px;">body</td><td style="width: 9.89401%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">integer</td><td style="width: 50.7747%; height: 46.6px;">ID of the format that will be used for the creative.</td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>advarTemplateName</code></td><td style="width: 11.7985%; height: 29.8px;">body</td><td style="width: 9.89401%; height: 29.8px;">Yes</td><td style="width: 9.29678%; height: 29.8px;">string</td><td style="width: 50.7747%; height: 29.8px;">Name of the advar template that will be used.</td></tr><tr style="height: 63.4px;"><td style="width: 18.236%; height: 63.4px;"><code>templateParameters</code></td><td style="width: 11.7985%; height: 63.4px;">body</td><td style="width: 9.89401%; height: 63.4px;">No</td><td style="width: 9.29678%; height: 63.4px;">string</td><td style="width: 50.7747%; height: 63.4px;">Additional parameters related to the advar. To be filled in as the macro of the parameter such as <code>&#60;CLICKURL&#62;</code> or <code>&#60;ALT&#95;TEXT&#62;</code>.</td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>templateFiles</code>

</td><td style="width: 11.7985%; height: 29.8px;">body</td><td style="width: 9.89401%; height: 29.8px;">No</td><td style="width: 9.29678%; height: 29.8px;">string</td><td style="width: 50.7747%; height: 29.8px;">Creative name and files.</td></tr><tr style="height: 63.4px;"><td style="width: 18.236%; height: 63.4px;"><code>key</code>

</td><td style="width: 11.7985%; height: 63.4px;">body</td><td style="width: 9.89401%; height: 63.4px;">Yes</td><td style="width: 9.29678%; height: 63.4px;">integer</td><td style="width: 50.7747%; height: 63.4px;">Creative file index written as ordinal number (e.g. 2) with the exception of 1, which has key "main" (but is not used in advar creatives). Default value is <code>main</code></td></tr><tr style="height: 29.8px;"><td style="width: 18.236%; height: 29.8px;"><code>&#45; fileName</code></td><td style="width: 11.7985%; height: 29.8px;">body</td><td style="width: 9.89401%; height: 29.8px;">No</td><td style="width: 9.29678%; height: 29.8px;">string</td><td style="width: 50.7747%; height: 29.8px;">Name of the creative's file.</td></tr><tr style="height: 46.6px;"><td style="width: 18.236%; height: 46.6px;"><code>&#45; filePath</code></td><td style="width: 11.7985%; height: 46.6px;">body</td><td style="width: 9.89401%; height: 46.6px;">No</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">Path where the file can be found. If a creative was uploaded via the API, this can be found in the response.</td></tr></tbody></table>

**Creating an advar creative**

```
{
  "campaignId": 27,
  "creativeName": "Apitestpotmancreative",
  "sku": null,
  "formatId": 1,
  "advarTemplateName": "Image_FlexBanner.html",
  "templateParameters": {
    "<CLICKURL>": "https://example.com",
    "<ALT_TEXT>": "My creative alt text"
  },
  "templateFiles": {
    "2": {
      "fileName": "banner.png",
      "filePath": "/home/adhese/www/docker.adhese.org/tmp/file_by_user_1_9072608199649672610.jpg"
    }
  }
}
```

**Response** - 201

```
{
    "creativeId": 29,
    "campaignId": 27,
    "creativeName": "Apitestpotmancreative",
    "formatId": 1,
    "advarTemplateName": "Image_FlexBanner.html",
    "sku": null,
    "lastEditedDate": "2026-09-02T13:25:48Z",
    "templateParameters": {
        "<CLICKURL>": "https://example.com",
        "<ALT_TEXT>": "My creative alt text"
    },
    "templateFiles": {
        "2": {
            "fileName": null,
            "filePath": "https://demo.preview.adhese.eu/pool/lib/29_2nd_1.jpg"
        }
    },
    "readonly": false,
    "lastEdited": 1788355548000
}
```

**Response codes**

<table id="bkmrk-status-meaning-201-f-1" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3027%;"></col><col style="width: 85.6973%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>201</code></td><td style="height: 29.8px;">File uploaded successfully.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr><td style="height: 29.8px;"><code>422</code></td><td style="height: 29.8px;">Unprocessable entity.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### Duplicate a creative

```
POST /v1/creatives/advar/{creativeId}/duplicate
```

Duplicates a chosen creative by campaign and creative ID.

**Request body**

<table id="bkmrk-parameter-in-require-6" style="border-collapse: collapse; width: 100%; height: 495.8px;"><thead><tr style="height: 29.8px;"><td style="width: 20.857%; height: 29.8px;">**Parameter**</td><td style="width: 9.17873%; height: 29.8px;">**In**</td><td style="width: 9.89273%; height: 29.8px;">**Required**</td><td style="width: 9.29678%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 46.6px;"><td style="width: 20.857%; height: 46.6px;"><code>creativeId</code></td><td style="width: 9.17873%; height: 46.6px;">path</td><td style="width: 9.89273%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">Id of the creative you wish to duplicate.</td></tr><tr style="height: 46.6px;"><td style="width: 20.857%; height: 46.6px;"><code>destinationCampaignId</code></td><td style="width: 9.17873%; height: 46.6px;">body</td><td style="width: 9.89273%; height: 46.6px;">Yes</td><td style="width: 9.29678%; height: 46.6px;">string</td><td style="width: 50.7747%; height: 46.6px;">The ID campaign to which the creative you wish to duplicate belongs.</td></tr></tbody></table>

**Duplicating a campaign**

```
{
   "destinationCampaignId": 27
}
```

**Response** - 200

```
{
    "creativeId": 30,
    "campaignId": 27,
    "creativeName": "Copy of Apitestpotmancreative",
    "formatId": 1,
    "advarTemplateName": "Image_FlexBanner.html",
    "sku": null,
    "lastEditedDate": "2026-09-08T08:00:13Z",
    "templateParameters": {
        "<CLICKURL>": "https://example.com",
        "<ALT_TEXT>": "My creative alt text"
    },
    "templateFiles": {
        "2": {
            "fileName": null,
            "filePath": "https://demo.preview.adhese.eu/pool/lib/30_2nd_1.jpg"
        }
    },
    "readonly": false,
    "lastEdited": 1788854413000
}
```

**Response codes**

<table id="bkmrk-status-meaning-200-c-3" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3027%;"></col><col style="width: 85.6973%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>200</code></td><td style="height: 29.8px;">Creative duplicated successfully.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>

### Deleting a creative

```
DELETE /v1/creatives/{id}
```

Removes a creative by ID.

**Request body**

<table id="bkmrk-parameter-in-require-8" style="border-collapse: collapse; width: 100%; height: 64.4px;"><thead><tr style="height: 29.8px;"><td style="width: 20.857%; height: 29.8px;">**Parameter**</td><td style="width: 9.17873%; height: 29.8px;">**In**</td><td style="width: 9.89273%; height: 29.8px;">**Required**</td><td style="width: 9.29678%; height: 29.8px;">**Type**</td><td style="width: 50.7747%; height: 29.8px;">**Description**</td></tr></thead><tbody><tr style="height: 34.6px;"><td style="width: 20.857%; height: 34.6px;"><code>creativeId</code></td><td style="width: 9.17873%; height: 34.6px;">path</td><td style="width: 9.89273%; height: 34.6px;">Yes</td><td style="width: 9.29678%; height: 34.6px;">string</td><td style="width: 50.7747%; height: 34.6px;">Id of the creative you wish to remove.</td></tr></tbody></table>

**Response** - 200

```
{
    "success": "DELETE on Creative 30 was successful",
    "key": 30
}
```

**Response codes**

<table id="bkmrk-status-meaning-200-b-1" style="border-collapse: collapse; width: 100%; height: 208.6px;"><colgroup><col style="width: 14.3027%;"></col><col style="width: 85.6973%;"></col></colgroup><thead><tr style="height: 29.8px;"><td style="height: 29.8px;">**Status**</td><td style="height: 29.8px;">**Meaning**</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>200</code></td><td style="height: 29.8px;">Bookings listed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>400</code></td><td style="height: 29.8px;">Bad request - invalid input or parameters.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>401</code> / <code>403</code></td><td style="height: 29.8px;">Not authenticated / not allowed.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>404</code></td><td style="height: 29.8px;">Not Found - Resource not found.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>409</code></td><td style="height: 29.8px;">Conflict.</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;"><code>500</code></td><td style="height: 29.8px;">Internal Server Error - Unexpected failure.</td></tr></tbody></table>