> ## Documentation Index
> Fetch the complete documentation index at: https://docs.thrad.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Ad Formats & Rendering

> Available ad formats, what each bid carries, and how to render and track it.

## Requesting a Format

Each opportunity lists the `formats` it can render, and for each one the parts (`assets`) it can draw. Every field is in the API reference: [`opportunities`](https://docs.thrad.ai/api/api-reference/bid-request-v2#opportunities) for the request, [Response](https://docs.thrad.ai/api/api-reference/bid-request-v2.md#response) for what comes back. List every format you can render: the server picks the best match, and each bid's `format` says what came back. Each format below shows how to request it.

| Format | `type` | Status |
| - | - | - |
| Card | `card` | Live |
| Carousel | `carousel` | Live, in a conversation only |
| Poll | `poll` | Live, in a conversation only |

Every bid has three parts: `assets` to draw, `trackers` to fire, and `actions` to call.

### Card

A native ad card shown inline in the conversation: a title, a description, brand visuals and a call to action.

**Request it** — `title` and `description` are required. Add `image` only if the opportunity can show a photo; leave it out for a text-only card with the advertiser's logo. `max_chars` on `title` (30 or more) caps its length.

```json theme={null}
{
  "type": "card",
  "assets": {
    "title": {
      "max_chars": 90
    },
    "description": {},
    "image": {}
  }
}
```

Listing a part allows it; it doesn't promise it. A card that lists `image` can still come back without one when the ad has no photo. A part you leave out never comes back. A card may also carry a `cta`, which you can't list.

A card comes in two looks. Both show `advertiser.logo_url` next to the brand name.

**With an image** — `assets.image` is present. Show it as the hero photo.

![Card with a product photo](https://mintcdn.com/thrads-5feffa3d/EdsOOrHNlfc3Ho7T/images/sponsored_message_2.png?fit=max\&auto=format\&n=EdsOOrHNlfc3Ho7T\&q=85\&s=16770810a204a7c61aa938d0dc41322b)

**Without an image** — `assets.image` is absent. Show a text-only card: no hero photo. Two reasons: you didn't ask for one (no `image` in your opportunity's `assets`), or you asked but this ad has no photo.

![Card without an image (text only)](https://mintcdn.com/thrads-5feffa3d/e8Y5mGsUZAhzRGKT/images/sponsored_message.png?fit=max\&auto=format\&n=e8Y5mGsUZAhzRGKT\&q=85\&s=06e91ef60676572f1453888150954f7f)

```json theme={null}
{
  "id": "bid_abc123",
  "price_cpm": 5.5,
  "currency": "USD",
  "ttl_ms": 3660000,
  "advertiser": {
    "name": "Nike",
    "domain": "nike.com",
    "logo_url": "https://cdn.example.com/nike-logo.png"
  },
  "trackers": [
    {
      "event": "viewable",
      "method": "pixel",
      "url": "https://ssp.thrads.ai/api/v1/tracking/ssp-view?token=v1"
    }
  ],
  "format": "card",
  "assets": {
    "title": "Premium Running Shoes",
    "description": "Perfect for marathon training. Lightweight and comfortable.",
    "cta": "Shop Now",
    "image": {
      "url": "https://cdn.example.com/nike-shoes.jpg"
    }
  },
  "actions": {
    "click_url": "https://dsp.thrad.ai/api/v1/tracking/redirect?token=abc123",
    "feedback_url": "https://dsp.thrad.ai/api/v1/tracking/feedback?token=fb123"
  }
}
```

| Field | Description |
| - | - |
| `price_cpm` | Clearing price per 1,000 impressions — what you earn. |
| `advertiser.name` | Brand name (e.g. `"Nike"`). Rarely falls back to the domain (e.g. `"nike.com"`); handle both. |
| `advertiser.domain` | Advertiser website domain. |
| `advertiser.logo_url` | Brand logo. Show it next to the brand name. |
| `assets.title` | Ad title. Respects the opportunity's `title.max_chars`. |
| `assets.description` | Ad body text. May be absent. |
| `assets.cta` | Call-to-action text. May be absent: default to "Learn More". |
| `assets.image.url` | Product photo, square (1:1). Absent when there is none, or when your opportunity didn't list `image`. |
| `actions.click_url` | Where a click goes. The whole card is the click target. |
| `actions.feedback_url` | Where to send thumbs up / down. May be absent. |
| `trackers` | Fire each at its `event`. See [Count the impression](#count-the-impression). |

### Carousel

A horizontally scrollable strip of 3–5 product cards from one advertiser. Each item shows a product **title, image and optional price**, and is its own click target. The strip shares one brand logo and one sponsored label.

**Request it** — `title` and `image` are both required: an item can't render without either. Only in a conversation, never before it starts.

```json theme={null}
{
  "type": "carousel",
  "assets": {
    "title": {},
    "image": {}
  }
}
```

![Sponsored carousel example](https://mintcdn.com/thrads-5feffa3d/EdsOOrHNlfc3Ho7T/images/carousel.png?fit=max\&auto=format\&n=EdsOOrHNlfc3Ho7T\&q=85\&s=d3a6f6db72cc17f26fd37633711e37d7)

Sponsored carousel in a chat interface

```json theme={null}
{
  "id": "bid_car_abc123",
  "price_cpm": 5.5,
  "currency": "USD",
  "ttl_ms": 3660000,
  "advertiser": {
    "name": "De'Longhi",
    "domain": "delonghi.com",
    "logo_url": "https://cdn.example.com/delonghi-logo.png"
  },
  "trackers": [
    {
      "event": "viewable",
      "method": "pixel",
      "url": "https://ssp.thrads.ai/api/v1/tracking/ssp-view?token=v1"
    }
  ],
  "format": "carousel",
  "assets": {
    "items": [
      {
        "title": "De'Longhi ECP3220 Espresso Machine",
        "image": {
          "url": "https://cdn.example.com/ecp3220.jpg"
        },
        "price": {
          "amount": "119.95",
          "currency": "USD"
        },
        "actions": {
          "click_url": "https://dsp.thrad.ai/api/v1/tracking/redirect?token=c0"
        }
      },
      {
        "title": "De'Longhi Dedica Grinder",
        "image": {
          "url": "https://cdn.example.com/dedica.jpg"
        },
        "price": {
          "amount": "89.00",
          "currency": "USD"
        },
        "actions": {
          "click_url": "https://dsp.thrad.ai/api/v1/tracking/redirect?token=c1"
        }
      },
      {
        "title": "De'Longhi Milk Frother",
        "image": {
          "url": "https://cdn.example.com/frother.jpg"
        },
        "actions": {
          "click_url": "https://dsp.thrad.ai/api/v1/tracking/redirect?token=c2"
        }
      }
    ]
  },
  "actions": {
    "feedback_url": "https://dsp.thrad.ai/api/v1/tracking/feedback?token=fb123"
  }
}
```

| Field | Description |
| - | - |
| `advertiser.logo_url` | Shared brand logo for the strip's sponsored header. |
| `assets.items` | The product cards, 3–5, in serving order. |
| `assets.items[].title` | Product name. |
| `assets.items[].image.url` | Product image, square (1:1). |
| `assets.items[].price` | Display price: `amount` as a string (e.g. `"119.95"`) and its `currency`. Absent when the product has no price — leave the price line out. |
| `assets.items[].actions.click_url` | Where a click on this item goes. There is no click for the strip as a whole. |
| `actions.feedback_url` | Where to send thumbs up / down for the whole strip. May be absent. |
| `trackers` | Fire each at its `event`, **once** for the whole strip. See [Count the impression](#count-the-impression). |

**Rendering rules:**

* Render items left to right in the order given. You may drop trailing items if space demands; never reorder.
* Items are always currently servable products. Render what you receive; don't cache across requests.

### Poll

An interactive poll sponsored by an advertiser, shown mid-conversation.

**Request it** — `question` and `options` are both required. Only in a conversation, never before it starts.

```json theme={null}
{
  "type": "poll",
  "assets": {
    "question": {},
    "options": {}
  }
}
```

![Sponsored poll example](https://mintcdn.com/thrads-5feffa3d/EdsOOrHNlfc3Ho7T/images/sponsored_poll.png?fit=max\&auto=format\&n=EdsOOrHNlfc3Ho7T\&q=85\&s=b129b5b199cc47e3fbdc4542e59aa40b)

Sponsored poll in a chat interface

```json theme={null}
{
  "id": "bid_poll_abc123",
  "price_cpm": 5.5,
  "currency": "USD",
  "ttl_ms": 3660000,
  "advertiser": {
    "name": "Warner Music Group",
    "domain": "warnermusic.com",
    "logo_url": "https://img.logokit.com/warnermusic.com"
  },
  "trackers": [
    {
      "event": "viewable",
      "method": "pixel",
      "url": "https://ssp.thrads.ai/api/v1/tracking/ssp-view?token=v1"
    }
  ],
  "format": "poll",
  "assets": {
    "question": "What kind of playlist are you making?",
    "options": [
      {
        "id": "0",
        "text": "Wedding"
      },
      {
        "id": "1",
        "text": "Study"
      },
      {
        "id": "2",
        "text": "Workout"
      }
    ],
    "cta": "Learn more"
  },
  "actions": {
    "vote_url": "https://ssp.thrads.ai/api/v1/tracking/sponsored-polls/vote?token=vote123",
    "click_url": "https://dsp.thrad.ai/api/v1/tracking/sponsored-polls/cta?token=cta123"
  }
}
```

| Field | Description |
| - | - |
| `assets.question` | The poll question. |
| `assets.options` | Two or more answers, each with an `id` and `text`. Vote with the `id`. |
| `assets.cta` | Label for the advertiser link shown after the vote. Present only with `actions.click_url`. |
| `actions.vote_url` | Where to send the vote. Always present. |
| `actions.click_url` | The advertiser link shown after the vote. May be absent. |
| `actions.feedback_url` | Where to send thumbs up / down. May be absent. |
| `trackers` | Fire each at its `event`. See [Count the impression](#count-the-impression). |

**Rendering rules:**

* Show the options as buttons. Don't wrap the whole poll in the advertiser link: an option tap is a vote, not a click.
* On tap, `POST` `{"option_id": "<id>"}` to `vote_url`, then show the results it returns.
* After the vote, show `assets.cta` linking to `actions.click_url`, when present.

See [Poll Voting](https://docs.thrad.ai/api/api-reference/poll-voting.md) for the vote endpoint.

## Rendering

Always label the ad as sponsored and show who it's from: **"Sponsored by `advertiser.name`"**.

Don't render a bid after its `ttl_ms` has passed.

### Count the impression

Each entry in `trackers` says which `event` it counts and the `method` to use. The method is always `pixel`: `GET` the `url` and ignore the response.

| `event` | Fire it |
| - | - |
| `rendered` | when you draw the ad, on screen or not. |
| `viewable` | once the ad is viewable: at least 50% on screen for at least 1 continuous second. |
| `click` | when the user clicks the returned advertiser action, if a click tracker is present. |

A bid can carry several entries for the same event. Fire every entry, each at its own moment, once per bid: a carousel's trackers fire once for the whole strip, not per item. An `event` you don't recognise: fire it at viewable.

The two moments exist because demand partners measure viewability as `viewable` over `rendered`. Firing both together reports every impression as viewable, which reads as invalid traffic and lowers what partners bid on your inventory.

> [!WARNING]
>
> You are paid on the `viewable` pixel only. Firing it before the ad is on screen inflates unverified impressions and lowers your payout. See [Impression Billing](https://docs.thrad.ai/api/guides/billing-viewability.md).

Fire them from the user's device, so the IP and user agent match the bid request. In the browser, that is your page's own code; on mobile, the app. Call this once per bid, with the ad's outermost container, so viewability is measured on the full ad area:

```javascript theme={null}
function trackContent(container, trackers) {
  const fire = (urls) => urls.forEach((url) => fetch(url, { mode: "no-cors", keepalive: true }));
  const pixels = trackers.filter((t) => t.method === "pixel");
  if (pixels.length !== trackers.length) console.warn("Unsupported tracker methods", { declared: trackers.length, supported: pixels.length });
  const rendered = pixels.filter((t) => t.event === "rendered").map((t) => t.url);
  const viewable = pixels.filter((t) => t.event !== "rendered" && t.event !== "click").map((t) => t.url);
  const clicks = pixels.filter((t) => t.event === "click").map((t) => t.url);

  fire(rendered);

  let timer;
  const observer = new IntersectionObserver(([entry]) => {
    if (entry.intersectionRatio >= 0.5) {
      timer ??= setTimeout(() => { fire(viewable); observer.disconnect(); }, 1000);
    } else {
      clearTimeout(timer);
      timer = undefined;
    }
  }, { threshold: 0.5 });
  observer.observe(container);

  let clicked = false;
  return () => {
    if (clicked) return;
    clicked = true;
    fire(clicks);
  };
}
```

The timer resets whenever the ad drops below 50%, so `viewable` fires only after one continuous second, and only once. An app does the same with its own visibility API: fire `rendered` when the view is drawn and `viewable` after 50% of it has been on screen for 1 second. If you must fire from your server instead, see [Impression Billing](https://docs.thrad.ai/api/guides/billing-viewability.md#fire-the-trackers-so-they-count) for the headers it needs.

### Handle the click

Keep the callback returned by `trackContent`. Call it from the advertiser action's trusted click handler, immediately before opening the applicable `click_url`. For a carousel, share that callback across item actions; do not call it for poll option votes. It sends any returned click pixels once.

Open the exact `click_url` when the user taps. It records the click and redirects to the advertiser. Don't rewrite it, add your own tracking to it, or fetch it in the background.

### Collect feedback

When a bid has `actions.feedback_url`, you can show thumbs up / thumbs down. On tap, `POST` to that URL (see the [Feedback reference](https://docs.thrad.ai/api/api-reference/feedback-v2.md)):

```json theme={null}
{
  "feedback_type": "negative",
  "feedback_text": "Not relevant to my conversation"
}
```

`feedback_type` is `positive` or `negative`. `feedback_text` is optional, up to 1,000 characters. Send one per ad.

### Report the auction

Only if you run your own auction across several SSPs (header bidding): call the bid's `win_url` or `loss_url`. Otherwise ignore them; every bid carries both, and you don't have to call either. See [Auction notices](https://docs.thrad.ai/api/api-reference/bid-request-v2.md#auction-notices).

## Publisher integration checklist

Before enabling a placement:

1. Read the returned `trackers` list for every format. Fire each `pixel` URL at its declared event; never fire both that list and legacy pixel aliases.
2. Keep URLs byte-for-byte, including query order, duplicate parameters and percent encoding. Do not recover extra pixels by parsing a click URL.
3. Bind tracking to the current bid and send each tracker once. Repeated render callbacks or clicks must not create another impression for that bid.
4. Keep viewability tracking active for polls without an advertiser CTA. Open the exact click URL only on a user action, without background fetching.
5. Declare only navigation support the host implements. [Mobile declarations](https://docs.thrad.ai/api/api-reference/bid-request-v2.md#optional-mobile-navigation-declarations) are optional: omission means unknown, not unsupported, and does not add a consent or advertising-ID requirement.
6. Verify accepted impressions with Thrad and the demand partner using the test bid and time window. A browser's opaque `no-cors` completion, a requested navigation or HTTP `204` alone is not proof of a billable impression or attribution.

| Client | Integration responsibility |
| - | - |
| Browser | Use page visibility and trusted click handlers; fire pixels from the user's browser. |
| Android/iOS native | Use host visibility callbacks and native networking; open the returned action from a real tap. |
| Android WebView / iOS WKWebView | Measure visibility inside the rendered placement and use an implemented navigation handler when an external browser is required. |
| Server forwarding | Use the endpoint's approved S2S contract and actual end-user headers; never invent an IP or user agent to bypass a rejection. See [Impression Billing](https://docs.thrad.ai/api/guides/billing-viewability.md#fire-the-trackers-so-they-count). |

Legacy integrations that read only link parameters can miss additional partner pixels, including when a click URL reaches its length limit. A CTA-less legacy poll may carry only its first beacon. Adopt the canonical list before claiming complete tracker support. A shorter returned list does not establish how many trackers a partner originally declared: unsupported trackers may have been filtered upstream. Do not invent replacement URLs; reconcile declared, accepted, carried and received counts during onboarding.

## No Bid

```json theme={null}
{
  "version": "2.0",
  "id": "req_124",
  "opportunities": [
    {
      "id": "opp_1",
      "bids": [],
      "no_bid_reason": "no_fill"
    }
  ]
}
```

A `200 OK` with an empty `bids` array is **not an error**. Show nothing there. `no_bid_reason` says why; see [No-bid reasons](https://docs.thrad.ai/api/api-reference/bid-request-v2.md#no-bid-reasons).

## Next steps

> [card] [User & Chat Identification](https://docs.thrad.ai/api/guides/user-identification-v2.md)
>
> Which ids to send, and why they raise your revenue.

> [card] [Impression Billing](https://docs.thrad.ai/api/guides/billing-viewability.md)
>
> Make sure every ad you show gets counted and paid.

Need exact fields? The [API Reference](https://docs.thrad.ai/api/api-reference/bid-request-v2.md) has every request and response.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.