# Instagram link clicks in the PubNio analytics API

PubNio reads Instagram post `link_clicks` only for Stories on accounts connected with Facebook Login: only that request adds Meta's `link_clicks`. Other posts keep the reading pending. At account level, `link_clicks` is Meta's daily `website_clicks`, summed over the range.

## What PubNio returns

| Metric | Scope | Instagram field | Unit | Combines by |
| --- | --- | --- | --- | --- |
| `link_clicks` | post | `link_clicks` (Stories on accounts connected with Facebook Login only) | count | sum |
| `link_clicks` | account | `website_clicks` | count | sum |

`link_clicks`: Outbound or website link clicks.

## How PubNio reads it

- The login method is stored on the connected account. An account connected through Instagram Login or unified login never sends `link_clicks` in the Story request.
- Account `link_clicks` is declared as renamed from `website_clicks` and is read with `views`, `reach`, and `profile_views` in one daily request.

## Example

The capabilities endpoint answers without calling Instagram. Under the Instagram provider, these are its entries for `link_clicks`.

```http
GET /api/v1/workspaces/4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b/analytics/capabilities
Authorization: Bearer pn_live_***
```

```json
[
  {
    "key": "link_clicks",
    "scope": "post",
    "granularity": "day",
    "unit": "count",
    "aggregation": "sum",
    "availability": "available",
    "supported": true,
    "renamedFrom": "link_clicks"
  },
  {
    "key": "link_clicks",
    "scope": "account",
    "granularity": "day",
    "unit": "count",
    "aggregation": "sum",
    "availability": "available",
    "supported": true,
    "renamedFrom": "website_clicks"
  }
]
```

## Limits

- PubNio stops re-reading an Instagram post 90 days after it is published, so a post's `link_clicks` stops changing then.
- An account `link_clicks` total is the last daily read's value for its window, 30 days before the read through the day of the read, whatever `from` and `to` the request names. Per-day values come from the daily series, which the workspace plan bounds.
- A metric Instagram does not report comes back with `value: null` and an availability state that says why. A post with no stored values whose last read failed on permissions, a rate limit, or a transient error answers with that error instead.

## Related

- [Instagram analytics API: the metrics PubNio reads](https://pubnio.com/platforms/instagram/analytics)
- [Instagram OAuth scopes](https://pubnio.com/docs/providers/instagram/scopes/)
- [API reference: analytics capabilities](https://pubnio.com/docs/reference/analytics-capabilities-get/)

