Skip to content

SystemRecordInput

github-actions[bot] edited this page Sep 21, 2026 · 1 revision

Interface: SystemRecordInput

Imported from @elite-dangerous-almanac/galaxy-map.

What a host passes to addSystems. It is the shape of an EDSM or a Spansh dump record. The type states the contract and the reader holds it: every field is still checked at run time, because the data comes from a file or a network call the compiler does not see.

The index signature lets a record carry fields the reader drops, so a caller does not have to strip a dump record first.

Indexable

[field: string]: unknown

A field the reader drops.

Properties

allegiance?

readonly optional allegiance?: string


bodyCount?

readonly optional bodyCount?: number


categories?

readonly optional categories?: readonly string[]

The names of categories the table holds, in the order the marker reads them. The first one gives the colour, the style and the draw range. A record may name none, which the reader takes while the category table is empty.


coords

readonly coords: object

The position in game coordinates, in light years.

x

readonly x: number

y

readonly y: number

z

readonly z: number


description?

readonly optional description?: string

A paragraph about the system, which the HUD shows.


government?

readonly optional government?: string


icons?

readonly optional icons?: readonly SystemIconInput[]

Up to 4 icons over the marker, lowest first. An entry is the symbol of a built-in icon or an object with the host's own url and the color of its arrow. It is the one optional field a bad value rejects the record for, rather than drops.


id64?

readonly optional id64?: string | number | bigint

The 64-bit system id. JSON.parse loses digits above 2^53, so a host that needs every digit passes a string or a bigint.


images?

readonly optional images?: readonly SystemImage[]

Up to 8 pictures, which the HUD shows as thumbnails.


name

readonly name: string


population?

readonly optional population?: number


primaryCategory?

readonly optional primaryCategory?: undefined

The two names categories replaces. Each one is never, so a record that carries it fails the compile.

The ban has to sit in the type. The index signature below turns off TypeScript's excess-property check, so a record naming primaryCategory beside categories would compile clean and the reader would drop it with no word to the caller.


primaryEconomy?

readonly optional primaryEconomy?: string


primaryStar?

readonly optional primaryStar?: string

The class of the primary star, for example K5 V.


secondaryCategories?

readonly optional secondaryCategories?: undefined


security?

readonly optional security?: string

Clone this wiki locally