Skip to content

Concepts

Concepts are formalized value types that wrap a primitive. They give every domain value a precise, strongly-typed name — you never pass a raw Uuid or String around — and they are where compliance is declared. Attributes control compliance behavior: Chronicle applies @pii and @sensitive rules automatically wherever the concept is used.

concept <Name> : <PrimitiveType> [<attributes>]
concept <Name> : Enum
<value>+

Uuid, String, Int, Decimal, Bool, Date, DateTime

AttributeMeaning
@piiThe value is personally identifiable information. Chronicle manages it and can erase it for GDPR compliance.
@sensitiveThe value is sensitive and handled under Chronicle’s sensitivity rules.
concept InvoiceId : Uuid
concept EmailAddress : String @pii
concept NationalIdNumber : String @pii @sensitive
concept DateOfBirth : Date @pii

An enum concept declares a fixed set of values as an indented list:

concept InvoiceStatus : Enum
draft
sent
paid
overdue
cancelled
concept PaymentTerms : Enum
net30
net60
immediate

When a concept is used as a property type on a command or event, its attributes are inherited — you never annotate at the property level. Declaring EmailAddress as @pii once means every event property, command property, and read model field typed as EmailAddress is treated as PII automatically.