# LinkedIn analytics API: the metrics PubNio reads

PubNio's LinkedIn adapter declares 7 post metrics and 9 account metrics as supported. It re-reads each post on a schedule for 365 days after publishing. A metric LinkedIn does not report comes back as null with a reason.

## What PubNio returns

| Metric | Post field | Account field |
| --- | --- | --- |
| `impressions` | `impressionCount` | `impressionCount` |
| `reach` | `uniqueImpressionsCount` | `uniqueImpressionsCount`, daily series only; a total is refused |
| `likes` | `likeCount`, else `totalLikes` | `likeCount` |
| `comments` | `commentCount`, else `totalFirstLevelComments` | `commentCount` |
| `shares` | `shareCount` | `shareCount` |
| `clicks` | `clickCount` | `clickCount` |
| `page_views` | — | `allPageViews.pageViews` |
| `followers` | — | `firstDegreeSize` |
| [follower_gained](https://pubnio.com/platforms/linkedin/analytics/metrics/followers-gained) | — | `organicFollowerGain` + `paidFollowerGain` |
| `engagement` | not returned: `saves_not_exposed` | not returned: `saves_not_exposed` |
| [engagement_rate](https://pubnio.com/platforms/linkedin/analytics/metrics/engagement-rate) | `engagement` | not returned: `ratio_not_aggregated` |

LinkedIn returns no value for the other keys, `views`, `saves`, `link_clicks`, `profile_visits`, `follows`, `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

- LinkedIn analytics cover organization Pages only. Capabilities declare only Page accounts, and the sync schedules reads only for declared account kinds, so PubNio never reads a member profile: its readings stay `pending`.
- A post is read from organization share statistics. If LinkedIn returns no statistics row for the share, PubNio falls back to the social actions endpoint, which yields likes and first-level comments only.

PubNio reads a LinkedIn post no sooner than 1 day after it is published; a post the sync pass finds later is read when it is found. After the first read it reads every 6 hours until day 7, daily until day 30, and weekly after that. It stops reading the post 365 days after publishing.

LinkedIn 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: 86400`, how long the adapter expects LinkedIn's numbers to take to settle. PubNio publishes the figure; reads are scheduled only by the rules above.

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

`reach`: LinkedIn reach is `uniqueImpressionsCount`. A post's lifetime value is its `reach` total. For a Page, PubNio keeps the daily values in the series but never adds them, so an account total returns `not_applicable` with reason `unique_not_summed`, although capabilities declare Page reach supported.

- The Page read sums impressions, clicks, likes, comments, and shares across the statistics rows in the range, and stores `uniqueImpressionsCount` only on each row's day.
- Unique counts are not additive, so neither the adapter nor the store turns daily reach into a running total.

`page_views`: `page_views` is an account-only metric, and LinkedIn Pages are where PubNio returns it: the value is `allPageViews.pageViews` from organization page statistics, added up across the range and kept per day in the series. Posts have no page views.

- Page views come from organization page statistics, a separate LinkedIn request from the share statistics behind impressions and clicks; the daily account sync makes both.

## Example

`impressions` is declared, and no daily account read has stored it yet, so it is `pending` with reason `not_published` until the first read lands. `engagement` and `engagement_rate` are metrics LinkedIn 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=impressions&metrics=engagement&metrics=engagement_rate
Authorization: Bearer pn_live_***
```

```json
[
  {
    "key": "impressions",
    "value": null,
    "availability": "pending",
    "reason": "not_published"
  },
  {
    "key": "engagement",
    "value": null,
    "availability": "unsupported",
    "reason": "saves_not_exposed"
  },
  {
    "key": "engagement_rate",
    "value": null,
    "availability": "unsupported",
    "reason": "ratio_not_aggregated"
  }
]
```

## Limits

- No views, saves, link clicks, profile visits, follows, or video metrics for LinkedIn posts, and no followers-lost count for Pages.
- 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)
- [LinkedIn engagement rate in the PubNio analytics API](https://pubnio.com/platforms/linkedin/analytics/metrics/engagement-rate)
- [LinkedIn followers gained in the PubNio analytics API](https://pubnio.com/platforms/linkedin/analytics/metrics/followers-gained)
- [LinkedIn publishing API](https://pubnio.com/platforms/linkedin)
- [LinkedIn OAuth scopes](https://pubnio.com/docs/providers/linkedin/scopes/)
- [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/)

