Link & QR Analytics
get_link_statsRetrieve analytics for the whole QRCodeKIT account or for one link. Reports total, unique, and repeat visits, unique-visitor ratio, activity over time, and — when the account plan supports advanced analytics — breakdowns by country, city, device, operating system, and browser. Account-wide results also include the number of links and the top links ranked by lifetime visits. Use this when the user asks about QR scans, short-link clicks, campaign performance, audience location, devices, trends, comparisons, or top-performing links. Every visit to the short URL is counted, so link clicks and QR scans are combined: one campaign can live in a printed QR, an Instagram bio, and an email and report in one place. Select a link by qr_id, slug, or part of its title via qr; omit it for the whole account. Defaults to the last 30 days; the interval can be auto, hourly, daily, weekly, or monthly. The structured result contains the full tables for answering questions about the data.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| qr | No | Optional link to deep-dive into: the QRCodeKIT qr_id, the short-link slug, or (part of) the link title. Omit for account-wide stats. | |
| end_date | No | Last day of the stats window (YYYY-MM-DD). Defaults to today. | |
| interval | No | Time-series bucket size: 1h, 1d, 1w, or 1M. Use 'auto' (default) to pick a sensible bucket from the range length. | auto |
| start_date | No | First day of the stats window (YYYY-MM-DD). Defaults to 29 days before end_date. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| qr | No | The QR the stats belong to when scope is 'qr'. | |
| scope | Yes | 'qr' for a single QR deep-dive, 'account' for all QRs in the account. | |
| cities | No | ||
| notice | No | Human-readable note about limits or missing data, if any. | |
| devices | No | ||
| summary | No | ||
| top_qrs | No | Account scope only: QRs ranked by lifetime visit totals. | |
| browsers | No | ||
| end_date | Yes | Last day of the stats window (YYYY-MM-DD). | |
| interval | Yes | Time-series bucket size: 1h, 1d, 1w, or 1M. | |
| qr_count | No | Account scope only: number of QRs covered by the stats. | |
| countries | No | ||
| start_date | Yes | First day of the stats window (YYYY-MM-DD). | |
| time_series | No | ||
| operating_systems | No | ||
| advanced_stats_available | No | False when the plan does not include advanced analytics breakdowns. |