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

# Insights

> Get live daily Snapchat ad metrics for the ads you boosted through Ayrshare, including spend, impressions, swipe-ups, CPM, CPC and CTR.

Get live Snapchat ad performance, one row per ad per day, for the ads you created with [Boost Post](https://www.ayrshare.com/docs/apis/ads/snapchat/boost-post.md).

<ul>
  <li>Numbers are read from Snapchat when you call. Use [History](https://www.ayrshare.com/docs/apis/ads/snapchat/get-ad-history.md) for the daily spend record.</li>
  <li>Snapchat reports by ad, so send `level=ad`. Other levels return `code: 101`.</li>
  <li>Days are the ad account's days, in its time zone. Money values are in the ad account's currency, returned in `currency` on each row.</li>
  <li>One request covers one ad account. Ads from several ad accounts return `code: 101`.</li>
  <li>An ad created through Ayrshare for another profile returns `code: 400`.</li>
  <li>Each ad is read from Snapchat once for every 31 days in the range, and one request can make at most 100 of these reads. For example, 50 ads over 62 days is 100 reads. A larger request returns `code: 101`: send fewer ads or a shorter range.</li>
</ul>

## Header Parameters

**Authorization** `string` *required*

[API Key](https://www.ayrshare.com/docs/apis/overview.md#authorization) of the Primary Profile.

Format: `Authorization: Bearer API_KEY`
**Profile-Key** `string`

[Profile Key](https://www.ayrshare.com/docs/apis/overview.md#profile-key-format) of a User Profile.

Format: `Profile-Key: PROFILE_KEY`

## Query Parameters

**level** `string` *required*

Must be `ad`.

**ids** `string`

Comma-separated Snapchat ad IDs, up to 50.

You can leave `ids` out and send `accountId` instead. This reports on the ads you boosted through Ayrshare for this profile in that ad account. If the account has more than 50 of your ads, the request returns `code: 101`: send their IDs instead. If none are found, the report is empty.

**accountId** `string`

The Snapchat ad account ID. Required when `ids` is left out. With `ids`, every ad Ayrshare has a record of must be in this account. An ID Ayrshare has no record of is read from whichever of your ad accounts holds it, so `accountId` does not limit it.

**metrics** `string`

Comma-separated metrics to return. Leave it out to get them all. See [Metrics](#metrics).

**startDate** `string` (default: 30 days ago)

First day, as `YYYY-MM-DD`. It can be up to 37 months ago.

**endDate** `string` (default: today)

Last day, as `YYYY-MM-DD`.

## Metrics

| Metric | Type | Meaning |
| - | - | - |
| `spend` | number | Amount spent |
| `impressions` | number | Times the ad was shown |
| `clicks` | number | Swipe-ups on the ad |
| `cpm` | number or `null` | Cost per 1,000 impressions. `null` on a day with no impressions |
| `cpc` | number or `null` | Cost per swipe-up. `null` on a day with no swipe-ups |
| `ctr` | number or `null` | Swipe-ups per impression, in percent. `null` on a day with no impressions |

Every row also has `swipes`, the same count as `clicks`, and `spendUsd`, which is `spend` when the currency is USD and `null` otherwise.

Snapchat does not report `reach`, `actions` or `conversionValue` by day. Asking for them returns `code: 101`. Snapchat also has no breakdowns, so sending `breakdowns` returns `code: 101`.

## Paging

Every row comes back in one response, so `meta.pagination.hasMore` is always `false`.

## Errors

| Code | When |
| - | - |
| `101` | A parameter is missing or wrong, `level` is not `ad`, a metric or breakdown isn't supported, `startDate` is more than 37 months ago, more than 50 ids are sent, `accountId` alone covers more than 50 of your ads, the ads are in more than one ad account, an ad is not in `accountId`, or the request needs more than 100 reads |
| `400` | An ad isn't yours, or `accountId` isn't the ad account Ayrshare has on record for the ads |
| `364` | Snapchat's rate limit was reached. Wait a minute and try again |
| `370` | Snapchat could not return the insights. Try again |

```bash cURL theme={"system"}
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/ads/snapchat/insights?level=ad&ids=c3a1e2d4-0000-4000-8000-0000000000ad&startDate=2026-11-20&endDate=2026-11-21"
```

```json 200: Success theme={"system"}
{
  "status": "success",
  "platform": "snapchat",
  "level": "ad",
  "startDate": "2026-11-20",
  "endDate": "2026-11-21",
  "insights": [
    {
      "date": "2026-11-20",
      "level": "ad",
      "id": "c3a1e2d4-0000-4000-8000-0000000000ad",
      "currency": "USD",
      "spend": 12.5,
      "impressions": 3000,
      "clicks": 30,
      "cpm": 4.17,
      "cpc": 0.42,
      "ctr": 1,
      "swipes": 30,
      "spendUsd": 12.5
    },
    {
      "date": "2026-11-21",
      "level": "ad",
      "id": "c3a1e2d4-0000-4000-8000-0000000000ad",
      "currency": "USD",
      "spend": 18,
      "impressions": 4000,
      "clicks": 42,
      "cpm": 4.5,
      "cpc": 0.43,
      "ctr": 1.05,
      "swipes": 42,
      "spendUsd": 18
    }
  ],
  "count": 2,
  "meta": { "pagination": { "hasMore": false } }
}
```

```json 400: Wrong level theme={"system"}
{
  "action": "request",
  "status": "error",
  "code": 101,
  "message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
  "details": "Insights on snapchat report by ad: use level \"ad\" with the ad ids."
}
```


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