Concerto models may be specified using either a JSON document, or using a set of domain-specific language files (the CTO format).
Each Concerto file (by convention with a .cto file extension) starts with the name and version of a single namespace. A Concerto namespace declares a set of declarations. A declaration is one of: enumeration, scalar, concept, asset, participant, transaction, event.
In order for one namespace to reference types defined in another namespace, the types must be imported from a versioned namespace. Via imports you can decompose your modles into discrete files (and namespaces), version them and build a graph of dependencies between your models.
Enumerations are used to capture static lists of domain values.
Primitive types (String, Boolean, Integer, Long, Double, DateTime) may be declared and reused via a scalar declaration.
Concepts are similar to class declarations in most object-oriented languages, in that they may have a super-type and a set of typed properties:
Class declarations contain properties. Each property has a type which can either be a type defined in the same namespace, an imported type, or a primitive type.
A relationship in Concerto Modeling Language (CML) is a tuple composed of:
Model elements may have arbitrary decorators (aka annotations) placed on them. These are available via API and can be useful for tool vendors to extend the metamodel.
📄️ Metamodel JSON
Concerto models may be fully represented via the metamodel JSON format.