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

# How to connect

> How to connect the The Trade Desk data source to Adriel: generate a long-lived API token, connect it, and select ad accounts.

The Trade Desk (TTD) is a leading independent demand-side platform for programmatic display, video, audio, native, and connected TV advertising. Connecting it imports campaign and ad-set performance from the TTD GraphQL API so programmatic spend can be analyzed alongside other paid channels.

## Before you connect

The following are required:

* A Trade Desk account with admin or operator access.
* A Trade Desk long-lived API token generated from the Partner Portal under **Manage API Tokens**. The token is supplied on every request through the `TTD-Auth` header.
* The ad account or accounts to be imported, available to the account that generated the token.

For ad-level (creative) metrics or custom conversions, use the [MyReport connector](/data-sources/o-z/the-trade-desk-my-report/how-to-connect) instead — those fields are not exposed by the standard GraphQL API.

## Connect The Trade Desk

<Steps>
  <Step title="Generate a long-lived API token in The Trade Desk">
    Log in to the Trade Desk Partner Portal, click the user profile icon at the top right, and open **Manage API Tokens**. Click **Generate Token**, enter a descriptive name (include the tool name to tell multiple tokens apart later), select **Platform API** in the **Application** field, choose the token **Lifetime**, and click **Save**. Copy the token shown in the confirmation message.
  </Step>

  <Step title="Select The Trade Desk in Adriel">
    On the **Data Sources** page, search for **The Trade Desk** and select it.
  </Step>

  <Step title="Enter the API token">
    In Connection Settings, paste the token into the **API token(key)** field and click **Submit**.
  </Step>

  <Step title="Select ad accounts and submit">
    In Data Source Settings, choose the **Ad Account** to connect from the dropdown. Multiple selections are allowed; one data source is created per ad account. Click **Submit** to complete the connection. The initial sync typically completes within one business day.
  </Step>
</Steps>

## What gets imported

The standard connector imports performance at the ad account, campaign, and ad-set levels: clicks, impressions, spend, media cost, bid CPM, bids, win rate, video ad plays, completion rate, and conversion revenue. Country, device, and daily breakdowns are available. Ad-level metrics and custom conversions are not exposed by the GraphQL API — use the MyReport connector for those.

For the complete list of metrics, breakdowns, and limits, see the [The Trade Desk data reference](/data-sources/o-z/the-trade-desk/data-reference).

## Troubleshooting

<AccordionGroup>
  <Accordion title="Ad-level data is missing">
    The TTD GraphQL API does not expose creative-level metrics, so the standard connector reports down to the ad-set level only. For ad-level analysis, configure a MyReport schedule that includes ad ID and connect via the MyReport connector.
  </Accordion>

  <Accordion title="Custom conversions are not appearing">
    Custom conversion events are not exposed by the GraphQL API. Use the MyReport connector with the relevant conversion fields included in the schedule.
  </Accordion>

  <Accordion title="Authentication fails after previously working">
    TTD API tokens do not expire automatically but can be revoked in the TTD admin. Regenerate the token in The Trade Desk and reconnect with the new value.
  </Accordion>

  <Accordion title="Non-aggregable metrics show unexpected totals">
    Bid CPM, win rate, and completion rate are weighted averages or percentages and cannot be summed across days or breakdowns. Dashboards flag these so they are not totalled in widgets.
  </Accordion>
</AccordionGroup>

## Related

<CardGroup cols={2}>
  <Card title="The Trade Desk data reference" href="/data-sources/o-z/the-trade-desk/data-reference">
    Metrics, breakdowns, and limits for The Trade Desk.
  </Card>

  <Card title="The Trade Desk FAQs" href="/data-sources/o-z/the-trade-desk/faqs">
    Common questions and expected behaviors for the The Trade Desk data source.
  </Card>

  <Card title="How to connect The Trade Desk MyReport" href="/data-sources/o-z/the-trade-desk-my-report/how-to-connect">
    Import ad-level metrics and custom conversions from a TTD MyReport schedule.
  </Card>

  <Card title="How to connect Amazon DSP" href="/data-sources/a-f/amazon-dsp/how-to-connect">
    Connect a comparable programmatic DSP.
  </Card>
</CardGroup>
