Gyroscopic 1.12.6

Gyroscopic API

Build your own front-end. Tailfin is one front-end for Gyroscopic. It does not have to be the only one. Gyroscopic serves all its data over a plain HTTP API with JSON responses, and anyone may write a dashboard, a report, an alerting script, a mobile app or a whole new front-end on top of it. This is encouraged. Use any language and any framework, and run it on your own hosts.

What you may doConnectFrom a browserBasicsThe dataEndpointsLimitsA small scriptTest status

What you may do

Gyroscopic is free to use for individuals and companies, for any purpose, on any number of hosts. Software you write that uses this API (or the MCP interface) is your own: you choose how to build it and how to license it, and you may give it away or sell it. The license covers only the SolidFokus applications themselves. Using their documented interfaces is what they are for; it is not modifying or reverse engineering them. The SolidFokus binaries themselves may not be redistributed, so point your users to download.solidfokus.com rather than bundling them.

How Tailfin does it

Tailfin is a server-side front-end: the browser talks only to Tailfin, and Tailfin reads Gyroscopic over HTTP with the read secret (user tailfin). It uses /api/v1/tags, /api/v1/latest, /api/v1/oldest, /api/v1/sequence and /api/v1/status. Your front-end can use the same endpoints or the fleet views (overview, health, series, episodes).

AI assistants: MCP

Gyroscopic also has an MCP interface for AI assistants, on its own port (3101) with its own secret. It is not needed for a front-end. Setup: Install Gyroscopic, section 5.

Connect

Address. http://<host>:3000 by default; Gyroscopic listens on 127.0.0.1 unless the operator set network.listen_address. With network.tls on, use https://: for the self-signed certificate, trust that certificate file (for example curl --cacert) or pin its SHA-256 fingerprint (gyroscopic --tls-info prints it). The settings are on Gyroscopic configuration.

Authentication. HTTP Basic auth with fixed user names. The passwords are the secrets in the config file.

GroupEndpointsUserPassword (config key)
HealthGET /healthnonenever needs auth
Readevery other /api/v1/ path (GET and HEAD, and POST /api/v1/series)tailfinauth.tailfin_secret
IngestPOST /api/v1/collecttracerlightauth.tracerlight_secret
MCPthe MCP portmcpauth.mcp_secret
TAILFIN_SECRET='<value of auth.tailfin_secret>'
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/tags?type=both"
# self-signed TLS: trust Gyroscopic's certificate (Linux path; FreeBSD and OpenBSD: /var/db/gyroscopic/tls/cert.pem)
curl -s --cacert /var/lib/gyroscopic/tls/cert.pem -u "tailfin:$TAILFIN_SECRET" "https://localhost:3000/api/v1/overview?type=client"

From a browser

Gyroscopic sends no CORS headers, so a web page served from another address cannot call it from browser scripts. Never put the read secret into a web page either: anyone who can open the page can read it. There are three ways to build on the API:

  1. Your own backend (as Tailfin does): your server calls Gyroscopic with the read secret; the browser talks only to your server.
  2. A same-origin proxy: NGINX serves your front-end's files and passes /api/v1/ to Gyroscopic on the same address. NGINX adds the read secret, so browsers never see it. Protect the proxy itself (a login, an allow list, or an internal network only): anyone who reaches it can read the data. Example below.
  3. Scripts and tools without a browser: call the API directly, with curl or any HTTP library (example).

NGINX same-origin proxy

Your front-end's files in /var/www/my-frontend, Gyroscopic on the same host at 127.0.0.1:3000. Everyone who opens the front-end logs in to NGINX with a user from /etc/nginx/dashboard.htpasswd (create one with printf 'alice:%s\n' "$(openssl passwd -apr1)" >> /etc/nginx/dashboard.htpasswd). Your page then calls relative URLs such as /api/v1/overview?type=client. Replace <BASE64> with the output of printf '%s' "tailfin:$TAILFIN_SECRET" | base64, and keep the file readable only by root and NGINX, since it holds the secret.

server {
    listen 443 ssl;
    server_name dashboard.example.net;
    ssl_certificate     /etc/ssl/dashboard/fullchain.pem;
    ssl_certificate_key /etc/ssl/dashboard/privkey.pem;

    # Everyone who opens the front-end logs in here (htpasswd file).
    auth_basic           "dashboard";
    auth_basic_user_file /etc/nginx/dashboard.htpasswd;

    # Your front-end: static files (HTML, CSS, scripts).
    root /var/www/my-frontend;
    location / {
        try_files $uri $uri/ =404;
    }

    # Never let browsers write data.
    location = /api/v1/collect {
        return 403;
    }

    # Read API, same origin. NGINX adds the read secret; browsers never see it.
    location /api/v1/ {
        proxy_pass http://127.0.0.1:3000;
        proxy_set_header Authorization "Basic <BASE64>";
        proxy_set_header Host $host;
        proxy_read_timeout 30s;
    }
}

Tested with 1.12.6-bcd8897 on Debian 13 (box), 2026-11-27, with NGINX 1.26: this block with a test certificate, port and paths changed. A login was required (401 without it), the static page was served, GET and POST /api/v1/series reached Gyroscopic with the secret added by NGINX, and /api/v1/collect answered 403. On Linux put the file in /etc/nginx/conf.d/; on FreeBSD see option 2, section 10, for the path and the include line. TLS settings as on Install Gyroscopic, section 4. Not yet tested on a real host: Gyroscopic on another host behind this proxy.

Basics

Error examples (real output):

$ curl -s -i "http://127.0.0.1:3000/api/v1/tags?type=both"
HTTP/1.1 401 Unauthorized
www-authenticate: Basic realm="gyroscopic"
x-request-id: a21cdd4b46
content-length: 12

Unauthorized

$ curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/tags?type=foo"
{"error":"invalid type 'foo': must be 'client' or 'server'"}

$ curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/latest?tag=SITE1-SITE2&type=client&limit=999999999"
{"error":"limit 999999999 exceeds maximum 1000000 (configure endpoints.max_query_limit to raise)"}

The data

Each Tracerlight process sends one record per interval (1 s by default). Gyroscopic keeps them per tag and type: client records come from Tracerlight clients, server records from Tracerlight servers.

Client records

FieldMeaning
tagWho sent it (see Tags below).
timestampSender clock, RFC 3339, nanoseconds.
sequenceGyroscopic's own counter for this tag, from 0.
eventstats every interval; final once when Tracerlight stops.
uptime_msTracerlight uptime.
sent, received, lostProbe packets: counters.
reordered, duplicatedPackets out of order or seen twice: counters.
too_low, too_highToo-low and too-high responses: counters.
send_error, recv_errorSocket errors: counters.
icmp_port_unreachable, icmp_host_unreachable, icmp_network_unreachableICMP errors received: counters.
rtt_min_ns, rtt_avg_ns, rtt_max_nsRound-trip time in this interval, ns: gauges.
rtt_p50_ns, rtt_p90_ns, rtt_p95_ns, rtt_p99_nsRTT percentile estimates for this interval, ns: gauges (0 = no data).

Server records

FieldMeaning
tag, timestamp, sequence, event, uptime_msAs for clients.
packets_received, packets_sentProbes answered: counters.
invalid_key, decode_errorProbes with the wrong --key or that could not be decoded: counters.
recv_error, send_errorSocket errors: counters.

How to read them

Endpoints

Examples assume TAILFIN_SECRET is set as in Connect, and use the tags SITE1-SITE2 and SITE3-SITE2 (clients) and SITE2_SRV1 (server). The outputs are real, from a test with a short burst of loss.

PathUse
/healthLiveness and version (no auth)
/api/v1/tagsLive tags
/api/v1/latestNewest records of a tag
/api/v1/oldestOldest records still held
/api/v1/dumpAll records of a tag (can be turned off)
/api/v1/sequenceRecords by sequence number
/api/v1/rangeRecords in a time window
/api/v1/changesWhere a counter went up
/api/v1/statusCounter totals for a tag
/api/v1/snapshotStatus plus newest records
/api/v1/overviewOne row per tag, short window
/api/v1/episodesLoss, RTT and restart runs
/api/v1/correlatedWhich tags had trouble at the same time
/api/v1/healthTags with problems, worst first
/api/v1/bucketsCoarse scan of the whole history
/api/v1/seriesChart columns for many tags (GET or POST)
/api/v1/semanticsWhat the data means (plain text)
/api/v1/collectData in from Tracerlight (POST, not for front-ends)

GET /health

Liveness and version. Never needs auth; use it for monitoring and to show the Gyroscopic version in your front-end. HEAD works too.

curl -s http://127.0.0.1:3000/health

Response (real output, shortened where marked):

{
  "status": "ok",
  "version": "1.12.6-bcd8897"
}

GET /api/v1/tags

The live tags. A tag is live while Gyroscopic holds data for it; it goes away after idle_timeout without data, or when Gyroscopic restarts. The order of tags is not defined; sort them yourself.

ParameterRequiredDefaultMeaning
typeyesclient, server or both.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/tags?type=both"

Response (real output, shortened where marked):

{
  "client": {
    "count": 2,
    "tags": ["SITE3-SITE2", "SITE1-SITE2"]
  },
  "server": {
    "count": 1,
    "tags": ["SITE2_SRV1"]
  }
}

With type=client or type=server the shape is flat: {"count":2,"tags":["SITE3-SITE2","SITE1-SITE2"],"type":"client"}.

GET /api/v1/latest

The newest records of one tag, oldest first within the result. The basic call for a "current value" display.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
limitno1Number of records to return. At most endpoints.max_query_limit (default 1000000).
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/latest?tag=SITE1-SITE2&type=client"

Response (real output, shortened where marked):

{
  "metadata": {
    "capacity": 691200,
    "count": 1,
    "max_sequence": 108,
    "min_sequence": 0,
    "newest_timestamp": "2026-11-27T11:58:25.163906736Z",
    "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"
  },
  "records": [
    {"duplicated": 0, "event": "stats", "icmp_host_unreachable": 0, "icmp_network_unreachable": 0, "icmp_port_unreachable": 384, "lost": 384, "received": 6592, "recv_error": 0, "reordered": 0, "rtt_avg_ns": 283970, "rtt_max_ns": 543359, "rtt_min_ns": 55610, "rtt_p50_ns": 294912, "rtt_p90_ns": 444708, "rtt_p95_ns": 458752, "rtt_p99_ns": 589824, "send_error": 0, "sent": 6976, "sequence": 108, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:58:25.163906736Z", "too_high": 0, "too_low": 0, "uptime_ms": 109001}
  ]
}

metadata describes what Gyroscopic holds for the tag: capacity (records it can hold), min_sequence/max_sequence, count (records returned) and the oldest and newest timestamps. A tag that does not exist (or was evicted) is not an error: the answer is 200 with {"records":[]} and no metadata.

GET /api/v1/oldest

The oldest records still held for a tag. Useful to show how far back the history goes.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
limitno1Number of records to return. At most endpoints.max_query_limit (default 1000000).
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/oldest?tag=SITE1-SITE2&type=client&limit=2"

Response (real output, shortened where marked):

{
  "metadata": {
    "capacity": 691200,
    "count": 2,
    "max_sequence": 108,
    "min_sequence": 0,
    "newest_timestamp": "2026-11-27T11:58:25.163906736Z",
    "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"
  },
  "records": [
    {"sequence": 0, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:56:37.163761350Z", "sent": 64, "lost": 0},
    {"sequence": 1, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:56:38.164124397Z", "sent": 128, "lost": 0}
  ]
}
(records shortened to five fields; the full record is shown under /api/v1/latest)

GET /api/v1/dump

Every record held for a tag, oldest first, or the oldest limit records. Without limit this can be hundreds of thousands of records; prefer latest, range or series. The operator can turn it off (endpoints.dump = false); the path then answers 404.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
limitnoallReturn only the oldest limit records.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/dump?tag=SITE1-SITE2&type=client&limit=100"

GET /api/v1/sequence

Records by sequence number: from an anchor forward (sequence ≥ seq) or backward (≤ seq). Results are always in ascending order. Use it to page through history or to fetch "everything after the last record I have".

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
seqyesAnchor sequence number (0 or more).
limitno1Number of records to return. At most endpoints.max_query_limit (default 1000000).
directionnoforwardforward or backward.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/sequence?tag=SITE1-SITE2&type=client&seq=10&limit=3"

Response (real output, shortened where marked):

{
  "metadata": {
    "capacity": 691200,
    "count": 3,
    "max_sequence": 108,
    "min_sequence": 0,
    "newest_timestamp": "2026-11-27T11:58:25.163906736Z",
    "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"
  },
  "records": [
    {"sequence": 10, "timestamp": "2026-11-27T11:56:47.163313749Z", "sent": 704, "lost": 0},
    {"sequence": 11, "timestamp": "2026-11-27T11:56:48.163414053Z", "sent": 768, "lost": 0},
    {"sequence": 12, "timestamp": "2026-11-27T11:56:49.164021572Z", "sent": 832, "lost": 0}
  ]
}
(records shortened to four fields)

An anchor that is no longer held, or is in the future, returns 200 with an empty records list and the tag's metadata, so you can see the current min_sequence and max_sequence.

GET /api/v1/range

Records whose sender timestamp lies in a time window (both ends inclusive, RFC 3339). Either end may be left out.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
fromnoStart of the window.
tonoEnd of the window.
limitno1Number of matching records. At most endpoints.max_query_limit (default 1000000).
directionnoforwardbackward fills the limit from the newest matches.
eventnostats or final.
fieldsnoComma-separated field names; each record then has only these plus tag, sequence and timestamp.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/range?tag=SITE1-SITE2&type=client&from=2026-11-27T11:57:25Z&limit=3&fields=lost,rtt_avg_ns"

Response (real output, shortened where marked):

{
  "metadata": {
    "capacity": 691200,
    "count": 3,
    "max_sequence": 108,
    "min_sequence": 0,
    "newest_timestamp": "2026-11-27T11:58:25.163906736Z",
    "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"
  },
  "records": [
    {"lost": 384, "rtt_avg_ns": 178984, "sequence": 48, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:57:25.164200940Z"},
    {"lost": 384, "rtt_avg_ns": 227893, "sequence": 49, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:57:26.163540456Z"},
    {"lost": 384, "rtt_avg_ns": 209465, "sequence": 50, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:57:27.164112746Z"}
  ]
}

The default limit is 1. Set it to the number of records you want.

GET /api/v1/changes

Records where a counter went up by at least min_delta since the record before it. Each match has an extra delta. Answers "when did the loss start?" without reading the whole buffer. A Tracerlight restart is never reported as a change.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
fieldyesA counter: client sent, received, lost, reordered, duplicated, too_low, too_high, send_error, recv_error, icmp_port_unreachable, icmp_host_unreachable, icmp_network_unreachable; server packets_received, packets_sent, invalid_key, decode_error, recv_error, send_error.
min_deltano1Smallest increase that counts.
fromnoWindow start.
tonoWindow end.
limitno1Number of matches. At most endpoints.max_query_limit (default 1000000).
directionnoforwardbackward finds the most recent changes.
fieldsnoAs for range; delta is always kept.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/changes?tag=SITE1-SITE2&type=client&field=lost&limit=5&fields=lost"

Response (real output, shortened where marked):

{
  "metadata": {
    "capacity": 691200,
    "count": 5,
    "max_sequence": 108,
    "min_sequence": 0,
    "newest_timestamp": "2026-11-27T11:58:25.163906736Z",
    "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"
  },
  "records": [
    {"delta": 63, "lost": 63, "sequence": 41, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:57:18.164289042Z"},
    {"delta": 64, "lost": 127, "sequence": 42, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:57:19.163395589Z"},
    {"delta": 64, "lost": 191, "sequence": 43, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:57:20.163449262Z"}
  ]
}
(first three of five matches shown)

GET /api/v1/status

Counter totals for one tag over everything Gyroscopic holds for it, returned at once. These are totals over the held window (restarts skipped), not lifetime totals since Tracerlight started.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/status?tag=SITE1-SITE2&type=client"

Response (real output, shortened where marked):

{
  "metadata": {
    "capacity": 691200,
    "count": 109,
    "max_sequence": 108,
    "min_sequence": 0,
    "newest_timestamp": "2026-11-27T11:58:25.163906736Z",
    "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"
  },
  "status": {
    "duplicated": 0,
    "icmp_host_unreachable": 0,
    "icmp_network_unreachable": 0,
    "icmp_port_unreachable": 384,
    "lost": 384,
    "received": 6528,
    "recv_error": 0,
    "reordered": 0,
    "send_error": 0,
    "sent": 6912,
    "tag": "SITE1-SITE2",
    "too_high": 0,
    "too_low": 0,
    "type": "client"
  }
}

An unknown tag returns 200 with {}.

GET /api/v1/snapshot

status plus the newest records of one tag in one call: a good fit for a per-tag detail view.

ParameterRequiredDefaultMeaning
tagyesThe tag to read.
typeyesclient or server.
limitno1Number of newest records. At most endpoints.max_query_limit (default 1000000).
fieldsnoLimits the fields of the records (not of status).
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/snapshot?tag=SITE1-SITE2&type=client&fields=lost,rtt_avg_ns"

Response (real output, shortened where marked):

{
  "latest": {
    "metadata": {"capacity": 691200, "count": 1, "max_sequence": 108, "min_sequence": 0, "newest_timestamp": "2026-11-27T11:58:25.163906736Z", "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"},
    "records": [{"lost": 384, "rtt_avg_ns": 283970, "sequence": 108, "tag": "SITE1-SITE2", "timestamp": "2026-11-27T11:58:25.163906736Z"}]
  },
  "status": {
    "metadata": {"capacity": 691200, "count": 109, "max_sequence": 108, "min_sequence": 0, "newest_timestamp": "2026-11-27T11:58:25.163906736Z", "oldest_timestamp": "2026-11-27T11:56:37.163761350Z"},
    "status": {"duplicated": 0, "icmp_host_unreachable": 0, "icmp_network_unreachable": 0, "icmp_port_unreachable": 384, "lost": 384, "received": 6528, "recv_error": 0, "reordered": 0, "send_error": 0, "sent": 6912, "tag": "SITE1-SITE2", "too_high": 0, "too_low": 0, "type": "client"}
  }
}

GET /api/v1/overview

One row per live tag for a short window: counter totals, the number of intervals and restarts, the first and last timestamps, silence_secs (seconds since the newest record), and for client tags the RTT values of the newest record plus rtt_p99_max_ns, the highest p99 in the window. The basic call for a fleet table.

ParameterRequiredDefaultMeaning
typeyesclient, server or both.
tagnoOnly this tag (exact).
tag_containsnoOnly tags that contain this text (case-sensitive, no wildcards).
samplesno60Use the newest N records of each tag (60 = the last minute at 1 s).
fromnoWindow start instead of samples.
tonoWindow end instead of samples.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/overview?type=client&samples=120"

Response (real output, shortened where marked):

{
  "count": 2,
  "evicted": [],
  "rows": [
    {
      "counters": {"duplicated": 0, "icmp_host_unreachable": 0, "icmp_network_unreachable": 0, "icmp_port_unreachable": 384, "lost": 384, "received": 6528, "recv_error": 0, "reordered": 0, "send_error": 0, "sent": 6912, "too_high": 0, "too_low": 0},
      "earliest_timestamp": "2026-11-27T11:56:37.163761350Z",
      "intervals": 108,
      "latest_timestamp": "2026-11-27T11:58:25.163906736Z",
      "restarts": 0,
      "rtt_max_ns": 543359,
      "rtt_p50_ns": 294912,
      "rtt_p99_max_ns": 7340032,
      "rtt_p99_ns": 589824,
      "samples": 109,
      "silence_secs": 0,
      "tag": "SITE1-SITE2",
      "type": "client"
    },
    {
      "counters": {"duplicated": 0, "icmp_host_unreachable": 0, "icmp_network_unreachable": 0, "icmp_port_unreachable": 96, "lost": 96, "received": 1632, "recv_error": 0, "reordered": 0, "send_error": 0, "sent": 1728, "too_high": 0, "too_low": 0},
      "earliest_timestamp": "2026-11-27T11:56:37.160270477Z",
      "intervals": 108,
      "latest_timestamp": "2026-11-27T11:58:25.159739086Z",
      "restarts": 0,
      "rtt_max_ns": 450680,
      "rtt_p50_ns": 240298,
      "rtt_p99_max_ns": 15728640,
      "rtt_p99_ns": 458752,
      "samples": 109,
      "silence_secs": 0,
      "tag": "SITE3-SITE2",
      "type": "client"
    }
  ]
}

evicted lists recently evicted tags (silent longer than idle_timeout), so a fleet view can show "gone" rather than just dropping a row.

GET /api/v1/episodes

Runs instead of single samples: consecutive intervals where a counter went up (for example a loss episode), a gauge stayed at or above a value, or a Tracerlight process restarted (kind=session). Good for an event list or for shading a chart.

ParameterRequiredDefaultMeaning
typeyesclient, server or both.
tagnoOnly this tag (exact).
tag_containsnoOnly tags that contain this text (case-sensitive, no wildcards).
samplesno60Use the newest N records of each tag (60 = the last minute at 1 s).
fromnoWindow start instead of samples.
tonoWindow end instead of samples.
fieldyes*A counter (as for changes) or a client RTT field such as rtt_p99_ns. *Not used with kind=session.
min_deltano1Smallest per-interval increase (counters).
min_valuefor gaugesSmallest gauge value that counts, in ns.
gapno0Clean intervals allowed inside a run before it closes.
limitno20Number of episodes.
directionnobackwardWhich end the limit keeps; the result is always oldest first.
kindnofrom fieldcounter, gauge or session.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/episodes?type=client&field=lost&samples=120"

Response (real output, shortened where marked):

{
  "count": 2,
  "episodes": [
    {"end_sequence": 47, "end_timestamp": "2026-11-27T11:57:24.159757241Z", "field": "lost", "intervals": 7, "kind": "counter", "peak_delta": 16, "start_sequence": 41, "start_timestamp": "2026-11-27T11:57:18.159685967Z", "sum_delta": 96, "tag": "SITE3-SITE2", "type": "client"},
    {"end_sequence": 47, "end_timestamp": "2026-11-27T11:57:24.164135737Z", "field": "lost", "intervals": 7, "kind": "counter", "peak_delta": 64, "start_sequence": 41, "start_timestamp": "2026-11-27T11:57:18.164289042Z", "sum_delta": 384, "tag": "SITE1-SITE2", "type": "client"}
  ]
}
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/episodes?type=server&kind=session&samples=200"
{
  "count": 1,
  "episodes": [
    {"end_sequence": 41, "end_timestamp": "2026-11-27T11:57:23.176641045Z", "event": "stats", "kind": "restart", "previous_uptime_ms": 41001, "start_sequence": 41, "start_timestamp": "2026-11-27T11:57:23.176641045Z", "tag": "SITE2_SRV1", "type": "server", "uptime_ms": 1000}
  ]
}

GET /api/v1/correlated

Which other tags had episodes on the same field at the same time as a reference tag. Answers "is this one path, or many?". The overlap test allows skew_secs of clock difference between senders.

ParameterRequiredDefaultMeaning
typeyesclient or server.
tagyesThe reference tag.
fieldyesAs for episodes.
tag_containsnoOnly compare against tags that contain this text.
samplesno60Use the newest N records of each tag (60 = the last minute at 1 s).
fromnoWindow start instead of samples.
tonoWindow end instead of samples.
min_deltano1As for episodes, or auto (half the largest increase seen on the reference tag).
min_valuefor gaugesAs for episodes, or auto.
gapno0As for episodes.
skew_secsno2Clock tolerance in seconds (max 3600).
limitno20Number of matching tags.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/correlated?type=client&tag=SITE1-SITE2&field=lost&samples=120"

Response (real output, shortened where marked):

{
  "checked": 1,
  "match_count": 1,
  "matches": [
    {"episodes": [{"end_sequence": 47, "end_timestamp": "2026-11-27T11:57:24.159757241Z", "field": "lost", "intervals": 7, "kind": "counter", "peak_delta": 16, "start_sequence": 41, "start_timestamp": "2026-11-27T11:57:18.159685967Z", "sum_delta": 96, "tag": "SITE3-SITE2", "type": "client"}], "overlap_ms": 5995, "tag": "SITE3-SITE2", "type": "client"}
  ],
  "reference": {
    "episodes": [{"end_sequence": 47, "end_timestamp": "2026-11-27T11:57:24.164135737Z", "field": "lost", "intervals": 7, "kind": "counter", "peak_delta": 64, "start_sequence": 41, "start_timestamp": "2026-11-27T11:57:18.164289042Z", "sum_delta": 384, "tag": "SITE1-SITE2", "type": "client"}],
    "field": "lost",
    "kind": "counter",
    "samples": 120,
    "tag": "SITE1-SITE2",
    "type": "client"
  }
}

GET /api/v1/health

Fleet triage: the same rows as overview, only for tags with a problem, worst first. Each row adds issues, loss_bp (loss in basis points: 100 = 1%) and expected_interval_ms. The issues, highest severity first: silent (no data for more than five intervals), loss, errors (send, receive and ICMP errors; on servers also key and decode errors), rtt (only when you pass rtt_warn_ns) and restarts. counts counts every evaluated tag per issue, plus healthy. This is a different path from /health above.

ParameterRequiredDefaultMeaning
typeyesclient, server or both.
tagnoOnly this tag (exact).
tag_containsnoOnly tags that contain this text (case-sensitive, no wildcards).
samplesno60Newest N records per tag. from and to are not accepted here (400).
rtt_warn_nsnop99 RTT in ns at or above which a client tag gets the rtt issue.
limitno20Number of rows.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/health?type=both&samples=120"

Response (real output, shortened where marked):

{
  "count": 3,
  "counts": {
    "errors": 2,
    "evaluated": 3,
    "healthy": 0,
    "loss": 2,
    "restarts": 1,
    "rtt": 0,
    "silent": 0
  },
  "rows": [
    {
      "counters": {"duplicated": 0, "icmp_host_unreachable": 0, "icmp_network_unreachable": 0, "icmp_port_unreachable": 384, "lost": 384, "received": 6528, "recv_error": 0, "reordered": 0, "send_error": 0, "sent": 6912, "too_high": 0, "too_low": 0},
      "earliest_timestamp": "2026-11-27T11:56:37.163761350Z",
      "expected_interval_ms": 1000,
      "intervals": 108,
      "issues": ["loss", "errors"],
      "latest_timestamp": "2026-11-27T11:58:25.163906736Z",
      "loss_bp": 555,
      "restarts": 0,
      "rtt_max_ns": 543359,
      "rtt_p50_ns": 294912,
      "rtt_p99_max_ns": 7340032,
      "rtt_p99_ns": 589824,
      "samples": 109,
      "silence_secs": 0,
      "tag": "SITE1-SITE2",
      "type": "client"
    },
    {
      "counters": {"decode_error": 0, "invalid_key": 0, "packets_received": 8162, "packets_sent": 8162, "recv_error": 0, "send_error": 0},
      "earliest_timestamp": "2026-11-27T11:56:36.158524040Z",
      "expected_interval_ms": 1058,
      "intervals": 102,
      "issues": ["restarts"],
      "latest_timestamp": "2026-11-27T11:58:25.176630129Z",
      "restarts": 1,
      "samples": 104,
      "silence_secs": 0,
      "tag": "SITE2_SRV1",
      "type": "server"
    }
  ]
}
(one of the two client rows shown)

GET /api/v1/buckets

A coarse scan over the whole history of each tag, cheap even for days of data. Gyroscopic keeps summary totals per block of records (bucket_records, default 1024); this returns spans of blocks where a field crossed a threshold. Use it to find "when, in the last week, was there loss?", then zoom in with range or episodes.

ParameterRequiredDefaultMeaning
typeyesclient, server or both.
tagnoOnly this tag (exact).
tag_containsnoOnly tags that contain this text (case-sensitive, no wildcards).
fieldyesAs for episodes.
min_deltano1Per-block increase that counts (counters).
min_valuefor gaugesPer-block maximum that counts.
fromnoWindow start.
tonoWindow end.
limitno20Number of spans.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/buckets?type=client&field=lost"

Response (real output, shortened where marked):

{
  "count": 2,
  "counts": {
    "evaluated": 2,
    "healthy": 0,
    "matched": 2
  },
  "spans": [
    {"buckets": 1, "end_sequence": 108, "end_timestamp": "2026-11-27T11:58:25.163906736Z", "field": "lost", "kind": "counter", "peak_delta": 384, "start_sequence": 0, "start_timestamp": "2026-11-27T11:56:37.163761350Z", "sum_delta": 384, "tag": "SITE1-SITE2", "type": "client"},
    {"buckets": 1, "end_sequence": 108, "end_timestamp": "2026-11-27T11:58:25.159739086Z", "field": "lost", "kind": "counter", "peak_delta": 96, "start_sequence": 0, "start_timestamp": "2026-11-27T11:56:37.160270477Z", "sum_delta": 96, "tag": "SITE3-SITE2", "type": "client"}
  ]
}

GET /api/v1/series

Chart data for many tags of one type in one call, as columns: the best fit for live charts. It replaces polling latest or sequence per tag.

ParameterRequiredDefaultMeaning
typeyesclient or server.
fieldsyesComma-separated fields to return as columns.
tagpaintTags to paint: repeat tag=A&tag=B or tag=A,B.
tag_containspaintPaint every live tag that contains this text (1–64 characters of letters, digits, _ and -).
afterfollowA cursor from next; repeat once per tag.
samplesno60 (paint)Records per tag when painting. At most endpoints.series_max_points (default 360).
limitno60 (follow)Points per tag when following.
timenorfc3339rfc3339 or offset.
curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/series?type=client&tag=SITE1-SITE2,SITE3-SITE2&fields=lost,rtt_avg_ns&samples=3"

Response (real output, shortened where marked):

{
  "busy": [],
  "failed": [],
  "fields": ["lost", "rtt_avg_ns"],
  "missing": [],
  "series": [
    {"cursor": 108, "gap": false, "lost": [0, 0], "max_sequence": 108, "min_sequence": 0, "next": "SITE1-SITE2:1cc143b236e14811:108", "reset": false, "restart": [false, false], "rtt_avg_ns": [262930, 283970], "run": "1cc143b236e14811", "sequence": [107, 108], "tag": "SITE1-SITE2", "timestamp": ["2026-11-27T11:58:24.163659502Z", "2026-11-27T11:58:25.163906736Z"], "truncated": false},
    {"cursor": 108, "gap": false, "lost": [0, 0], "max_sequence": 108, "min_sequence": 0, "next": "SITE3-SITE2:e386884bdd02c5bd:108", "reset": false, "restart": [false, false], "rtt_avg_ns": [239528, 250390], "run": "e386884bdd02c5bd", "sequence": [107, 108], "tag": "SITE3-SITE2", "timestamp": ["2026-11-27T11:58:24.159808288Z", "2026-11-27T11:58:25.159739086Z"], "truncated": false}
  ]
}

Paint and follow. First paint: ask for the tags with tag or tag_contains and samples. Every series has a next cursor (TAG:RUN:SEQUENCE). Then follow: send the cursors back as after (one per tag) and you get only the new points. If a series comes back with gap or reset set to true (history evicted, or the tag or Gyroscopic restarted), replace that line with the returned points. A tag listed in missing has no data now: keep its last cursor. A tag in busy was skipped this time; ask again.

Points. Counter columns are increases per interval, not running totals; a restart interval is null and marked in restart. RTT columns are the values as sent. samples=N reads N records and returns up to N−1 points, because the oldest record is only the starting value. With time=offset each series has t0 and dt_ms (milliseconds from t0) instead of a list of timestamps.

Follow, with the next cursor from the paint:

curl -s -u "tailfin:$TAILFIN_SECRET" "http://127.0.0.1:3000/api/v1/series?type=client&after=SITE1-SITE2:1cc143b236e14811:221&fields=lost,rtt_avg_ns"
{
  "busy": [],
  "failed": [],
  "fields": ["lost", "rtt_avg_ns"],
  "missing": [],
  "series": [
    {"cursor": 224, "gap": false, "lost": [0, 0, 0], "max_sequence": 224, "min_sequence": 0, "next": "SITE1-SITE2:1cc143b236e14811:224", "reset": false, "restart": [false, false, false], "rtt_avg_ns": [144324, 212015, 208053], "run": "1cc143b236e14811", "sequence": [222, 223, 224], "tag": "SITE1-SITE2", "timestamp": ["2026-11-27T12:00:19.164224451Z", "2026-11-27T12:00:20.163510715Z", "2026-11-27T12:00:21.163744997Z"], "truncated": false}
  ]
}

from and to are not accepted here (400 series does not accept from or to).

POST /api/v1/series

The same call with the parameters in a JSON body. Use it beyond a few hundred tags, where a GET line gets too long. Requires Content-Type: application/json (otherwise 415). The body may be up to 1024 + series_max_tags × 112 bytes.

curl -s -u "tailfin:$TAILFIN_SECRET" -H "Content-Type: application/json" \
  -d '{"type":"client","tag_contains":"SITE2","fields":"lost,rtt_avg_ns","samples":2}' \
  http://127.0.0.1:3000/api/v1/series

The answer has the same shape as the GET call. In the body, tag and after can be JSON arrays.

GET /api/v1/semantics

A plain-text reference on what the data means: tag conventions, counters and gauges, how to read windows and changes. The same text AI assistants get over MCP. Worth reading once before you build charts.

curl -s -u "tailfin:$TAILFIN_SECRET" http://127.0.0.1:3000/api/v1/semantics

POST /api/v1/collect

How data gets in: each Tracerlight process posts one JSON record per interval as user tracerlight. A front-end does not need this endpoint; it is listed so you know where the data comes from. Keep it away from browsers (the NGINX example blocks it). Body up to 1 KB, Content-Type: application/json. Answers 202 with {"status":"ok","sequence":42}.

Limits

The operator sets these in the config; the defaults are shown.

LimitDefaultWhat you see
Records per call (limit, samples)1000000 (max_query_limit)400 with the maximum in the message
Points per tag in series360 (series_max_points)400
Tags per series call4096 (series_max_tags)400
Size of one series answer (tags × points × fields)500000 (series_max_cells)400
Concurrent series calls (HTTP and MCP together)4 (series_max_calls)503; try again
Request time10 s (request_timeout_secs)503
Body size1 KB; POST /api/v1/series: 1024 + series_max_tags × 112 bytes413 (plain text)

Poll gently: once per interval (1 s) is the most that is useful, since a tag gains one record per interval. For live charts, follow with series cursors rather than re-reading whole windows.

A small script

Loss per client tag over the last 5 minutes, with only the Python standard library (no browser, so no CORS question):

import base64, json, os, urllib.request

BASE = "http://127.0.0.1:3000"
AUTH = base64.b64encode(("tailfin:" + os.environ["READ_SECRET"]).encode()).decode()

def get(path):
    req = urllib.request.Request(BASE + path, headers={"Authorization": "Basic " + AUTH})
    with urllib.request.urlopen(req, timeout=15) as r:
        return json.load(r)

# Loss per client tag over the last 5 minutes (300 records at 1 s)
for row in get("/api/v1/overview?type=client&samples=300")["rows"]:
    c = row["counters"]
    pct = 100.0 * c["lost"] / c["sent"] if c["sent"] else 0.0
    print(f'{row["tag"]:24} sent={c["sent"]:>8} lost={c["lost"]:>6} ({pct:.2f}%)')
$ TAILFIN_SECRET='<value of auth.tailfin_secret>' python3 loss.py
SITE1-SITE2              sent=   16064 lost=   384 (2.39%)
SITE3-SITE2              sent=    4016 lost=    96 (2.39%)

Test status

Tested with 1.12.6-bcd8897 on Debian 13 (box), 2026-11-27: every curl example on this page against a Gyroscopic fed by a local Tracerlight 2.22.1 server and two clients over loopback, with one forced burst of loss (the outputs shown); the error examples; the self-signed TLS example; the Python script; and the NGINX proxy (see its note). Not yet tested on a real host: the API over a network between hosts, Gyroscopic's allow list with a remote front-end, and the 503 cases (request timeout, call cap).

Configuration: Gyroscopic configuration. Install: Install Gyroscopic.