Documentation · API reference
GET
/api/v1/sites/{site}/liveReal time
This page as Markdown, or in an AI chatMore ways to read this page
Who is on a site now, by page.
# Real time
> tidekeeper's API reference: https://tidekeeper.eu/docs/api/get-sites-site-live
`GET /api/v1/sites/{site}/live`
Who is on a site now, by page.
## Parameters
- `site` (in path, needed): A site's id or name
## The answer
200, `LiveResponse`: Who is on a site now, by page. Never by reader (RT-02).
- `countries` (list of Counted, needed)
- `current` (integer, needed): Visitors seen in the last five minutes.
- `last_hit` (string or null): When the site last had a counted hit.
- `minutes` (list of integer, needed): Views in each of the last thirty minutes, oldest first.
- `pages` (list of Counted, needed)
- `sources` (list of Counted, needed)
## Asking
```sh
curl https://tidekeeper.eu/api/v1/sites/example.org/live \
-H "Authorization: Bearer $TIDEKEEPER_TOKEN"
```
Parameters
- sitein the address
- neededA site's id or name
The answer
Status 200
LiveResponse Who is on a site now, by page. Never by reader (RT-02).
- countries
- list of Countedneeded
- current
- integerneededVisitors seen in the last five minutes.
- last_hit
- string or nullWhen the site last had a counted hit.
- minutes
- list of integerneededViews in each of the last thirty minutes, oldest first.
- pages
- list of Countedneeded
- sources
- list of Countedneeded
Asking
curl https://tidekeeper.eu/api/v1/sites/example.org/live \ -H "Authorization: Bearer $TIDEKEEPER_TOKEN"
const answer = await fetch("https://tidekeeper.eu/api/v1/sites/example.org/live", { headers: { Authorization: `Bearer ${process.env.TIDEKEEPER_TOKEN}`, }, }).then((r) => r.json());