Skip to content

Overview

Telemachus Reborn API (1.7.0)

Real-time telemetry API for Kerbal Space Program.

REST API

Each telemetry key has its own endpoint:

GET /api/v.altitude        → { "v.altitude": 12500.0 }
GET /api/o.PeA             → { "o.PeA": 75000.0 }
GET /api/o.orbitalSpeedAt?1200.0  → pass args via query string

Batch API

Query multiple keys in a single call:

GET /telemachus/datalink?key1=v.altitude&key2=o.PeA

Returns all values as properties in one JSON object. Parameters are passed via bracket notation: key1=o.orbitalSpeedAt[1200.0]

WebSocket Streaming

Connect to ws://host:8085/datalink and send subscription commands:

{ "+": ["v.altitude", "o.PeA"], "rate": 500 }

Scaling for Embedded Controllers

Both /api/ and /telemachus/datalink support optional scaling parameters for integer-only embedded boards (Raspberry Pi Pico, MicroBlocks, etc.):

REST API (/api/)

ParameterDescriptionExample
scale=min,maxMap input arg from [min,max] to [0,1]?args=512&scale=0,1023
precision=NRound output to N decimal places?precision=212345.68
int=trueReturn output × 10^N as integer?precision=2&int=true1234568 (divide by 100 on board)

Global defaults via reserved query parameters:

  • _scale=0,1023 — default input scale for all action args
  • _precision=2 — round all numeric outputs to 2 decimal places
  • _int=true — return all outputs as integers

Per-key overrides via pipe syntax in the value string:

  • alt=v.altitude|precision:2|int → 18.19 becomes 1819; divide by 100 on the board
  • t=f.setThrottle[512]|scale:0,1023 → scale 10-bit ADC value to 0.0–1.0 throttle

Per-key pipe modifiers override global _ parameters.

Mod Integrations

Endpoints tagged with x-requires-mod are only available when the corresponding mod is installed. Query a.mods to check which mods are detected at runtime.

  • License: MIT
  • OpenAPI version: 3.1.0