# Threads analytics API: the metrics PubNio reads

Threads is upcoming on PubNio: no account can connect yet, so PubNio returns no Threads analytics today. Its adapter is already in the code and declares 4 post metrics and 6 account metrics, listed below with the Threads field each one reads.

## What PubNio returns

| Metric | Post field | Account field |
| --- | --- | --- |
| `impressions` | not returned: `threads_reports_views` | not returned: `threads_reports_views` |
| `views` | `views` (lifetime total only) | `views` |
| `likes` | `likes` (lifetime total only) | `likes` |
| `comments` | `replies` (lifetime total only) | `replies` |
| `shares` | `reposts` + `quotes` + `shares` (lifetime total only) | `reposts` + `quotes` |
| `clicks` | not returned: `threads_reports_link_clicks` | not returned: `threads_reports_link_clicks` |
| `link_clicks` | not returned: `not_exposed` | `clicks` |
| `followers` | — | `followers_count` |
| `engagement` | not returned: `saves_not_exposed` | not returned: `saves_not_exposed` |
| `engagement_rate` | not returned: `saves_not_exposed` | not returned: `saves_not_exposed` |

Threads returns no value for the other keys, `reach`, `saves`, `profile_visits`, `page_views`, `follows`, `follower_gained`, `follower_lost`, `watch_time_ms`, `avg_watch_time_ms`, and `completion_rate`: the adapter marks each `not_exposed` or leaves it out.

## How PubNio reads it

- A Threads post is read in two requests: views, likes, replies, reposts, and quotes, then `shares` alone. If the second fails, shares are reposts plus quotes; if either reposts or quotes is missing, there is no shares reading.
- An account read covers at most the 30 UTC dates ending on the range end, never starts before 2024-04-13, and ends no later than the time of the read.

PubNio reads a Threads post no sooner than 30 minutes after it is published; a post the sync pass finds later is read when it is found. After the first read it reads every 30 minutes until it is a day old, every 6 hours until day 7, daily until day 30, and weekly after that. It stops reading the post 365 days after publishing. A refresh request does not wait for that: it reads the post as soon as 15 minutes after publishing.

Threads returns lifetime totals for a post, so PubNio stores each read's increase on the UTC day of the read. The first read puts the whole total on that day, only summed metrics get daily points, and a total that drops is stored as zero, not a negative day.

Account metrics are read once a day, each time for the UTC dates from 30 days before the read through the day of the read, and readings count as stale two days after the last read.

Capabilities also declare `latencySeconds: 3600`, how long the adapter expects Threads's numbers to take to settle. PubNio publishes the figure; reads are scheduled only by the rules above.

PubNio's Threads analytics capabilities require these OAuth scopes on the connected account: `threads_basic`, `threads_manage_insights`. When one is missing, the sync marks the metrics `permission_missing` and lists what is absent in `missingScopes`.

## Example

`views` is declared, and no daily account read has stored it yet, so it is `pending` with reason `not_published` until the first read lands. `impressions` and `clicks` are metrics Threads does not supply: each comes back `unsupported` with its reason. The request answers 200 with one entry per key.

```http
GET /api/v1/workspaces/4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b/analytics/accounts/7f3c2a10-5b4e-4d6f-8a9b-0c1d2e3f4a5b?metrics=views&metrics=impressions&metrics=clicks
Authorization: Bearer pn_live_***
```

```json
[
  {
    "key": "views",
    "value": null,
    "availability": "pending",
    "reason": "not_published"
  },
  {
    "key": "impressions",
    "value": null,
    "availability": "unsupported",
    "reason": "threads_reports_views"
  },
  {
    "key": "clicks",
    "value": null,
    "availability": "unsupported",
    "reason": "threads_reports_link_clicks"
  }
]
```

## Limits

- Threads reports `views` instead of impressions (`threads_reports_views`), and account link clicks instead of clicks (`threads_reports_link_clicks`); posts have neither clicks nor link clicks. No reach, saves, or engagement.
- A request covers at most 366 days and 30 metrics, in UTC dates, and defaults to the last 30 days. How far back a daily series reaches depends on the workspace plan, and stored daily points are deleted after 400 days.

## Related

- [Analytics metrics on every network](https://pubnio.com/platforms/analytics)
- [Threads API errors](https://pubnio.com/docs/errors/threads/)
- [Problem: analytics metric unsupported](https://pubnio.com/docs/problems/analytics-metric-unsupported/)
- [API reference: read one account's analytics](https://pubnio.com/docs/reference/analytics-accounts-get/)

