Properties
Maryk models are built from properties. Each property declares the data type, how the value is validated and how it is stored. This page gives a high‑level overview of the available property types and common concepts for working with them.
Property Type Characteristics
Section titled “Property Type Characteristics”The table below lists the available property types and where they can be used.
| Type | Keyable | Indexable | List/Set | MapKey | MapValue | MultiType |
|---|---|---|---|---|---|---|
| String | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Boolean | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Number🔢 | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Enum | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| GeoPoint | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Date | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Time | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| DateTime | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Reference | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| FixedBytes | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| FlexBytes | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ |
| MultiType | 🆔 | ✅ | ❌ | ❌ | ✅ | ✅ |
| List | ❌ | ❌ | ❌ | ❌ | ✅ | ✅ |
| Set | ❌ | ✅ | ❌ | ❌ | ✅ | ✅ |
| Map | ❌ | 🔑 | ❌ | ❌ | ✅ | ✅ |
| IncMap | ❌ | 🔑 | ❌ | ❌ | ✅ | ✅ |
| Embed | ❌ | ⤵️ | ❌ | ❌ | ✅ | ✅ |
| ValueObject | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ |
🔢 All numeric properties such as Int8/16/32/64, UInt8/16/32/64, Float, Double
🆔 Only the type ID of multi types can be used in the key
🔑 Only the map key can be indexed
⤵️ Only nested values inside the embedded object can be indexed
Characteristic meanings
Section titled “Characteristic meanings”- Keyable – Property can participate in a key. Key properties must be required and final.
- MapKey – Property can be used as the key of a map.
- MapValue – Property can act as the value in a map.
- MultiType – Property can be part of a multi type.
- List/Set – Property can be stored inside a list or set.
Operations
Section titled “Operations”Use property operations such as change, delete or check to inspect or modify values. See the operations page for details.
References
Section titled “References”Property references point to specific fields within a model and are used for filters and sorting.
Validation
Section titled “Validation”Every property definition supports validation helpers. Common options include:
- required – the property must be set (default
true) - final – value cannot change once set (default
false) - default – value to use if none is provided (default
null)
Each type may define extra validations such as minSize, maxSize, ranges or regex patterns. Refer to the individual type pages for full details.