Documentation
Export every click
GET
/v1/clicksAnalyticsEvery click and scan across the account in the range, newest first, with the link's ending on each row. Needs the Pro plan (Free answers 403 forbidden with details.upgrade). A CSV carries the newest 50,000 rows of the range; narrow days or add filters for the rest.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
days | integer | optional | How many UTC days back, today included. Free shows 30 days; Pro shows 365. A larger value is capped; max_days in the answer says where. Default 30. |
country | string | optional | Exact two-letter country code, or unknown for missing country. |
referrer | string | optional | Exact referring hostname, or direct for no referrer. No URL path. |
device | string | optional | Exact device class: desktop, mobile or tablet. |
channel | string | optional | qr for marked QR scans, link for ordinary link clicks. Omit for both. |
cursor | string | optional | The next_cursor from the preceding JSON page. Keep the same filters and days. Do not combine with before. |
before | integer, null | optional | Legacy exclusive timestamp. Prefer cursor for lossless pagination when timestamps tie. |
format | json | csv | optional | csv streams every row in the range as text/csv (no paging). Default json. |
Example request
Terminal
curl "https://snip.link/v1/clicks?days=30" \
-H "Authorization: Bearer $SNIP_KEY"Example response
Response
{
"clicks": [
{
"ts": "2026-10-19T18:41:03.000Z",
"code": "spring-menu",
"country": "US",
"referrer": null,
"device": "mobile",
"via_qr": true,
"os": "ios",
"browser": "safari"
}
],
"next_before": null,
"next_cursor": null
}With format=csv the answer is text/csv, one row per click, sent as a file download:
Response fields
| Field | Type | Description |
|---|---|---|
clicks | ClickRow[] | Newest first, up to 5,000 per page. |
next_cursor | string, null | Pass as cursor for the next page. Preserves clicks with identical timestamps. Null on the last page. |
next_before | integer, null | Legacy exclusive timestamp cursor. Use next_cursor instead to preserve timestamp ties. |
Errors
| Status | Meaning |
|---|---|
| 400 | The body or query is invalid. details names each field. |
| 401 | The API key is missing, malformed or revoked. |
| 403 | The plan does not include this. details.upgrade names the plan that does. |
| 429 | Either the key exceeded its requests-per-second limit (honor Retry-After), or a daily or plan quota is used up (details.reason). |

