Skip to main content

Lookups and Reference Data

Reference data provides the controlled vocabularies, enumerations, and master records that domain modules use for dropdown lists, validation, and display formatting. Foundation centralises this data so that every module draws from a single source of truth.

Lookups

A lookup is a named enumeration — a category of allowed values. Each lookup has a type code that other areas of the platform reference.

Key attributes:

AttributePurpose
TypeUnique code within the tenant
NameHuman-readable name with i18n support
Customisation levelControls whether tenants can modify the values

Lookup values

Individual values within a lookup. Each value belongs to exactly one lookup type:

AttributePurpose
CodeMachine-readable code (e.g. FILE, URL, SHORT_TEXT)
MeaningDisplay text with i18n support
Display sequenceSort order within the lookup
Enabled flagWhether the value is selectable (without deleting it)
TagOptional grouping tag for filtering subsets

Validation

Lookups are validated when data is saved — the platform ensures that any referenced lookup value exists and is active. This allows lookups to be disabled without breaking existing references.

Key-value pairs

A simpler alternative to lookups for arbitrary configuration data. Key-value pairs store tenant-scoped settings that do not need the structured enumeration model:

AttributePurpose
KeyUnique key within the tenant
ValueThe stored value
DescriptionWhat the setting controls

Countries

Master list of countries with standardised codes and geographic metadata:

AttributePurpose
Country codeISO 3166-1 alpha-2 code (e.g. NZ, AU, US)
Alpha-3 codeISO 3166-1 alpha-3 code (e.g. NZL, AUS, USA)
NameDisplay name with i18n support
NationalityDemonym (e.g. New Zealander, Australian)
Region/sub-regionGeographic classification
Phone codeInternational dialling prefix

Currencies

Master list of currencies with formatting and rounding rules:

AttributePurpose
Currency codeISO 4217 code (e.g. NZD, AUD, USD)
NameDisplay name with i18n support
PrecisionDecimal places for arithmetic
Minimum accountable unitSmallest unit (e.g. 0.01 for cents)
Rounding ruleHow to round amounts
SymbolDisplay symbol (e.g. $, , £)

Units of measure

Standard units for quantities across the platform:

AttributePurpose
CodeUnique code (e.g. KG, LB, EA)
NameDisplay name with i18n support
ClassCategory (e.g. WEIGHT, LENGTH, QUANTITY)
Base unitBase unit for conversion within the class
Conversion rateMultiplier to convert to base unit

How other modules use reference data

Other modules reference lookup values by storing the lookup code (e.g. as a category or status code). The platform validates these references when data is saved, ensuring consistency.

Countries and currencies are referenced by their ISO codes. Units of measure are referenced by their unit code. All reference data is tenant-scoped.