Standard Data Type schema reference
This page is a field-by-field reference for the YAML documents behind entries in the
My Standard Types tab of Settings.
It's aimed at anyone hand-editing or reviewing a Standard Data Type definition rather than
just using the UI. Each entry is a single YAML document; an account-scoped entry with the
same
key as a Global (built-in) entry overrides it for that account.
Data Type entry
| Field | Required | Type | Notes |
|---|---|---|---|
key |
Required | string | Entry identity within account scope. Overrides a Global entry of the same key. |
name |
Required | string | May embed a ${variant} placeholder token. |
kind |
Required | enum | One of BYTE, CHAR, SHORT, INTEGER,
LONG, BOOLEAN, FLOAT, DOUBLE,
NUMERIC, DATETIME, TIME, STRING,
TEXT. Matching is case-insensitive - YAML in practice uses lowercase
(e.g. "numeric"). |
base-units |
Required | string | Free-form - not restricted to an enum (observed examples: m/s,
degC, hPa, ug/m^3). Paired with
attributes.display-units to convert to a display unit, e.g. base
m/s → display km/h. |
profiles |
Optional | list of enum (profile code) | e.g. ["A"], ["A", "T"] - single-letter codes from the
Profiles table. If
omitted, the data type is treated as applicable to all profiles. |
description |
Optional | string | Longer-form explanation shown alongside name. In practice only set on
entries whose name is abbreviated (e.g. name: "Min. Air
Temperature" → description: "Minimum Air Temperature") -
most entries omit it and rely on name alone. |
variant-type |
Optional | string (key ref) | External reference — must match a Data Variant Type key (global or
account scope). A dangling reference is flagged. |
modulo |
Optional | boolean | Despite the name, this is a boolean flag rather than a modulus number - e.g.
physical/heading sets modulo: true to mark that its
valid-range ([0, 360]) wraps rather than clamps. |
valid-range |
Optional | tuple [lower, upper] |
Must be exactly 2 numbers if present. |
synonyms |
Optional | list of strings | Legacy/alternate field-name aliases for migration and lookup, e.g.
["windSpeed"], ["lat"]. |
deprecated |
Optional | boolean | Soft-deprecation flag - hides/flags the entry without deleting it. |
attributes |
Optional | object | See Data Type attributes below. Unlike the top-level Device Config document, this object isn't restricted to a known key set - unrecognised keys are accepted and passed through. |
Data Type attributes (nested object, all fields optional)
Structurally validated - the client checks type, shape, and enum membership.
| Field | Type |
|---|---|
display-units | {si, imperial}, each a display-scale string, e.g. si: "0.1 km/h". |
display-units-unicode | {si, imperial}, unicode display of the unit symbol, e.g. si: '°C'. |
payload-encoding | {si, imperial}, each integer 0–15 - number of encoded bytes/precision slots for the wire payload. |
display-order | enum: lowest, low, medium, high, highest - relative priority for ordering the data type in a UI list. |
display-plot-style | {colour: enum c0–c7, fill: boolean} - plot line colour slot and whether the area under the line is filled. |
display-stats-style | enum: min-only, min-max, avg-only, min-avg-max, max-only. |
display-allowed | list, values restricted to live, tracker, plot, hist, map, qc, dashboard - the UI surfaces the data type is displayed on. |
display-axis-range | {lower, upper} (numeric, required), step (numeric, optional) - e.g. {lower: 0, upper: 360, step: 30} sizes axis tick/gridline spacing. |
spike-filter | {delta, max-repeats} (numeric) - a jump of more than delta between consecutive readings is treated as a spike and suppressed for up to max-repeats occurrences. |
Free-form - accepted and passed through, but not structurally validated client-side.
| Field | Observed usage |
|---|---|
display-axis-labels | Map of numeric axis value → short label string, for compass-style axes, e.g. {0: "N", 90: "E", 180: "S", 270: "W"}. |
editing-allowed | Boolean, present on almost every entry. Whether the value is user-editable in the app (true for planned/target/manual-entry values) vs. read-only/derived (false). |
relative-to | String - reference datum for a vertical measurement, e.g. "MSL" (mean sea level) on altitude/depth types. |
positive | String, "up" or "down" - direction of increasing value relative to relative-to. |
angle-convention | String, e.g. "degrees_north" - which compass convention the angle is measured against. |
vector-components | List of related data type keys forming a vector pair, e.g. ["sensed/wind-speed", "sensed/wind-direction"]. |
related-data-types | List of related data type keys shown together in the UI (e.g. a value and its planned/applied counterpart, or a min/max pair). |
Data Variant Type entry
| Field | Required | Type | Notes |
|---|---|---|---|
key |
Required | string | Entry identity. Referenced by a Data Type's variant-type. |
name |
Required | string | Display name of the variant group, e.g. "Spreading Material". |
description |
Optional | string | Longer-form explanation of the variant group; most entries omit it in favour of name. |
deprecated |
Optional | boolean | Soft-deprecation flag, same semantics as the Data Type field. |
values |
Required | non-empty list of {key, name} |
Internal nested structure: the variant's selectable option set, e.g.
{key: "lime", name: "Lime"}. |
Cross-entry rules
- Reference — a Data Type's
variant-typepoints to a Data Variant Type'skey(many-to-one). - Integrity constraint — a Data Variant Type referenced by any Data Type cannot be deleted while it's still referenced.
- Scope override — an account entry with the same
keyas a Global entry supersedes it for that account; non-matching keys are additive. - Key composition — a Data Type
keymay embed a${variant}token linking it to the referenced variant type's keyspace.
Example
key: "sensed/particulate-matter/10" name: "10um Particulate Matter" kind: "double" base-units: "ug/m^3" profiles: ["E", "W"] attributes: display-allowed: ["dashboard", "hist", "live", "map", "plot"] display-order: "high" display-plot-style: colour: "c1" fill: "false" display-stats-style: "min-avg-max" display-units: imperial: "ug/m^3" si: "ug/m^3" editing-allowed: "true"