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

# Toppie API

> Learn what you can do with the Toppie API

The Toppie API gives agencies and brands programmatic access to their Toppie account. Use it to manage campaigns, read the bids Toppie sets for them, pull performance reports, and list the products the account can advertise.

All requests go to the following base URL:

```sh theme={null}
https://api.topsort.com/public/v1/toppie
```

Every request needs a Toppie agency API key. Marketplace and Advanced API keys from Topsort Admin do not work on these endpoints. See [Toppie authentication](https://docs.topsort.com/en/api-reference/toppie/authentication.md) to create one.

> [!NOTE]
>
> All Toppie endpoints are in beta. Their request and response shapes can still change.

## What You Can Do

The **Toppie API** endpoint group in this reference documents every request, parameter and response field. The API covers the following areas.

> [card] [Campaigns](https://docs.topsort.com/en/api-reference/toppie-api/%5Bbeta%5D-get-toppie-campaigns)
>
> Create, update and delete Sponsored Listings campaigns, and set their budget, dates and product targets. Banner campaigns can be read and deleted through the API, and are created and updated in the Toppie UI.

> [card] [Bids](https://docs.topsort.com/en/api-reference/toppie-api/%5Bbeta%5D-get-toppie-campaign-bids)
>
> Toppie sets and adjusts bids automatically. You choose which products a campaign targets, and you can read the bid Toppie currently places for each one.

> [card] [Products](https://docs.topsort.com/en/api-reference/toppie-api/%5Bbeta%5D-list-account-products)
>
> List the products your account can advertise and use them as campaign targets. The catalog is read only through the API.

> [card] [Reports](https://docs.topsort.com/en/api-reference/toppie-api/%5Bbeta%5D-get-agency-account-report)
>
> Pull performance for the whole account, for each campaign, or for each product in a campaign, over the date range you choose. Each report returns a fixed set of metrics.

> [card] [Account Activity](https://docs.topsort.com/en/api-reference/toppie-api/%5Bbeta%5D-account-activity-reports)
>
> Read the account's transaction history, with one row per day for ad spend and for ad credit top-ups.

## Rate Limits

The Toppie API allows 10 requests per second per API key. Requests above the limit receive `429 Too Many Requests`.

Every response includes the `X-RateLimit-Limit`, `X-RateLimit-Remaining` and `X-RateLimit-Reset` headers. `X-RateLimit-Reset` is the number of seconds until the limit resets. See [Toppie errors](https://docs.topsort.com/en/api-reference/toppie/handling-errors.md#rate-limiting) for how to retry.

## Sandbox

The Toppie API has no separate sandbox key or base URL. To test an integration without affecting live campaigns, contact your Toppie account manager to set up a sandbox agency and accounts.


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