Documentation · API reference
GET
/api/v1/definitionsWhat every figure means
This page as Markdown, or in an AI chatMore ways to read this page
What every figure means: the one definition of each metric, the reasons a hit is left out, the channel rules, and what the script sends.
# What every figure means
> tidekeeper's API reference: https://tidekeeper.eu/docs/api/get-definitions
`GET /api/v1/definitions`
What every figure means: the one definition of each metric, the reasons a hit is left out, the channel rules, and what the script sends.
## The answer
200, `Definitions`: Everything tidekeeper's figures mean, in one place (ME-11): the same text the UI, the CLI and the emails show.
- `caveats` (list of CaveatView, needed)
- `channels` (list of ChannelRule, needed)
- `dimensions` (list of string, needed)
- `fields` (list of FieldDef, needed): What the script sends: the whole list (SC-16).
- `metrics` (list of MetricDef, needed)
- `reasons` (list of ReasonDef, needed)
## Asking
```sh
curl https://tidekeeper.eu/api/v1/definitions \
-H "Authorization: Bearer $TIDEKEEPER_TOKEN"
```
The answer
Status 200
Definitions Everything tidekeeper's figures mean, in one place (ME-11): the same text the UI, the CLI and the emails show.
- caveats
- list of CaveatViewneeded
- channels
- list of ChannelRuleneeded
- dimensions
- list of stringneeded
- fields
- list of FieldDefneededWhat the script sends: the whole list (SC-16).
- metrics
- list of MetricDefneeded
- reasons
- list of ReasonDefneeded
Asking
curl https://tidekeeper.eu/api/v1/definitions \ -H "Authorization: Bearer $TIDEKEEPER_TOKEN"
const answer = await fetch("https://tidekeeper.eu/api/v1/definitions", { headers: { Authorization: `Bearer ${process.env.TIDEKEEPER_TOKEN}`, }, }).then((r) => r.json());