# Creatives (coming soon)

Creatives represent the design files that the advertiser would like to appear on the ads.

We currently accept .jpg and .png file types.&#x20;

### The Creative Object

```
id: integer
name: string
url: string
advertiser_id
width: integer (width in pixels)
height: integer (height in pixels)
approvals: array
rejections: array
campaigns: array of campaing_id and approval status (PENDING | APPROVED | REJECTED)
```

### Endpoints

#### Summary

```
POST /creatives #=> Create creative
GET /creatives #=>  List creatives
POST /creatives/:id/campaign/:campaign_id #=> Request approval for campaign
GET /creatives/:id #=> Get specific creative
```

#### Create Creative

## POST /v1/campaigns/{campaign\_token}/creatives

> create Creative

```json
{"openapi":"3.0.1","info":{"title":"API V1","version":"v1"},"servers":[{"url":"https://{defaultHost}","variables":{"defaultHost":{"default":"api.adquick.com"}}}],"paths":{"/v1/campaigns/{campaign_token}/creatives":{"post":{"summary":"create Creative","parameters":[{"name":"campaign_token","in":"path","required":true,"schema":{"type":"string"}},{"name":"X-PARTNER-TOKEN","in":"header","schema":{"type":"string"}}],"responses":{"200":{"description":"successful","content":{"application/json":{"schema":{"$schema":"http://json-schema.org/draft-06/schema#","type":"object","properties":{"id":{"type":"integer","not":{"type":"null"}},"programmatic_plan_id":{"type":"integer","not":{"type":"null"}},"upload_id":{"type":"integer","not":{"type":"null"}},"approved_at":{"type":["null","string"],"format":"date"},"rejected_at":{"type":["null","string"],"format":"date"},"created_at":{"type":"string","format":"date","minLength":1},"updated_at":{"type":"string","format":"date","minLength":1},"iab_category_id":{"type":["null","integer"]},"width":{"type":"string","minLength":1},"height":{"type":"string","minLength":1},"external_id":{"type":"string","minLength":1},"error_at":{"type":["null","string"],"format":"date"},"deleted_at":{"type":["null","string"],"format":"date"},"ignore_video":{"type":["null","string"],"format":"date"},"error":{"type":["null","string"]},"resolution_id":{"type":["null","integer"]},"metadata":{"type":["null","object"]},"file_hash":{"type":"string","minLength":1},"dcm_tag":{"type":["null","string"]},"dcm_video_duration":{"type":["null","string"]},"dcm_video_bitrate":{"type":["null","string"]}},"required":["id","programmatic_plan_id","upload_id","created_at","updated_at","iab_category_id","width","height","external_id","resolution_id","file_hash"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"$schema":"http://json-schema.org/draft-06/schema#","type":"object","properties":{"file_url":{"type":"string","minLength":1}},"required":["file_url"]}}}}}}}}
```

#### List Creatives

```
GET /creatives

Expects:
- advertiser_id (optional) #=> filters responses to only that advertiser

Returns: paginated array of creatives inside a "records" key
```

#### Request approval for campaign

```
POST /creatives/:id/campaign/:campaign_id

Expects:
- creative_id
- campaign_id

Returns: Creative Object
```

#### Get Creative

```
GET /creatives/:id

Expects:
- id

Returns: the creative object
```
