> For the complete documentation index, see [llms.txt](https://docs.exoclick.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.exoclick.com/api/de/exoclick-public-api/api-manual-postman-examples.md).

# Postman-Beispiele

## Überblick

Dieser Leitfaden bietet Schritt-für-Schritt-Anweisungen zum Authentifizieren und Erstellen von Kampagnen über die ExoClick-API mit Postman. Alle Beispiele geben den erforderlichen Request-Typ, die Header und das Body-Format für jeden Endpunkt an.

## Authentifizierung (Login)

Du kannst dich mit deinen Kontodaten oder einem permanenten API-Token authentifizieren. Beide geben ein temporäres Bearer-Token zurück, das für alle nachfolgenden Anfragen verwendet wird.

{% tabs %}
{% tab title="Login mit Benutzername und Passwort" %}
**Request-Typ:** `POST`\
**URL:** `https://api.exoclick.com/v2/login`

**Header:**

```
Content-Type: application/json
```

**Body (rohes JSON):**

```json
{
  "username": "YOUR_USERNAME",
  "password": "YOUR_PASSWORD"
}
```

{% endtab %}

{% tab title="Login mit API-Token" %}
Verwende dies, wenn du im ExoClick-Dashboard ein Token generiert hast (Profil > API-Token).

**Request-Typ:** `POST`\
**URL:** `https://api.exoclick.com/v2/login`

**Header:**

```
Content-Type: application/json
```

**Body (rohes JSON):**

```json
{
  "api_token": "YOUR_API_TOKEN"
}
```

{% endtab %}
{% endtabs %}

## Ablauf zur Erstellung einer 300x250-Bannerkampagne

Befolge diese Schritte exakt in der angegebenen Reihenfolge. Beachte den Übergang von JSON zu Form-Data in den letzten Schritten.

{% stepper %}
{% step %}

### Landingpage-URL erstellen (Bibliothek)

Registriert deine Ziel-URL. Standard-Banner benötigen eine `id_library_url`.

**Request-Typ:** `POST`\
**URL:** `https://api.exoclick.com/v2/library/url`

**Header:**

```
Authorization: Bearer YOUR_TOKEN
Content-Type: application/json
```

**Body (rohes JSON):**

```json
{
  "url": "https://your-landing-page.com"
}
```

**Ergebnis:** Speichere die zurückgegebene `"id"` (z. B., `6512406`).
{% endstep %}

{% step %}

### Bild hochladen (Bibliothek)

Registriert dein Creative-Asset. Das Bild muss exakt 300x250 groß sein.

**Request-Typ:** `POST`\
**URL:** `https://api.exoclick.com/v2/library/file`

**Header:**

```
Authorization: Bearer YOUR_TOKEN
```

**Body (Form-Data):**

| Schlüssel | Typ   | Wert                                |
| --------- | ----- | ----------------------------------- |
| `file`    | Datei | Wähle deine Bilddatei aus (300x250) |
| `type`    | Text  | `image`                             |

**Ergebnis:** Speichere die zurückgegebene `"id"` (z. B., `6884966`).
{% endstep %}

{% step %}

### Kampagnen-Gerüst erstellen

Legt Targeting, Budget und die `img_banner` Vorlage fest.

**Request-Typ:** `POST`\
**URL:** `https://api.exoclick.com/v2/campaigns`

**Header:**

```
Authorization: Bearer YOUR_TOKEN
Content-Type: application/json
```

**Body (rohes JSON):**

```json
{
  "name": "Banner 300x250 Production",
  "status": 0,
  "advertiser_ad_type": 0,
  "media_storage_template": "img_banner",
  "size": "300x250",
  "categories": {
    "type": "targeted",
    "elements": [97, 98, 99]
  },
  "countries": {
    "type": "targeted",
    "elements": [
      {
        "country": "USA",
        "regions": [0]
      }
    ]
  },
  "pricing": {
    "model": 4,
    "price": 300
  },
  "start_date": "2026-03-02",
  "daily_limit_type": 1,
  "max_daily_budget": 2000,
  "budget_delivery_mode": 1,
  "run_on_responsive_zones": 1
}
```

**Ergebnis:** Speichere die zurückgegebene `"id"` (z. B., `8140060`).
{% endstep %}

{% step %}

### Variante hinzufügen

Verknüpft die URL (Schritt 1) und das Bild (Schritt 2) mit der Kampagne (Schritt 3).

**Request-Typ:** `POST`\
**URL:** `https://api.exoclick.com/v2/campaigns/8140060/variation`\
\&#xNAN;*(Ersetze `8140060` durch deine tatsächliche Kampagnen-ID aus Schritt 3)*

**Header:**

```
Authorization: Bearer YOUR_TOKEN
```

**Body (Form-Data):**

| Schlüssel         | Typ  | Wert                        |
| ----------------- | ---- | --------------------------- |
| `id_library_url`  | Text | `6512406` *(aus Schritt 1)* |
| `id_library_file` | Text | `6884966` *(aus Schritt 2)* |
| `active`          | Text | `1`                         |

Alle IDs, die in jedem Schritt zurückgegeben werden, müssen gespeichert und in nachfolgenden Anfragen verwendet werden. Denke daran, `YOUR_TOKEN`, Dateipfade und IDs durch deine tatsächlichen Werte zu ersetzen.
{% endstep %}
{% endstepper %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.exoclick.com/api/de/exoclick-public-api/api-manual-postman-examples.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
