Base profile & modeling
This page describes how to model applications using the Base platform.
It focuses on:
- simple types
- REST modeling
- method types
- pseudocode for sequence diagrams
- layers
- how the model maps to OpenAPI + diagram artefacts
Release baseline
This page targets JoinedWorkz 1.3.80. Its model fragments and release-specific generator boundaries were source- and syntax-checked by 2026-07-26. Exact built output paths belong to the separately verified Base example.
1. Simple types
Provided by the common-base model Base.cmn:
String,Integer,Long,BooleanDate,Time,Timestamp- semantic helper types like
Id
Used across all higher‑level platforms.
2. REST modeling with resources
Example:
resource /hello as Greeting {
read sayHello()
}2.1 Method types
Base provides:
Raw method types:
get→ GETpost→ POSTput→ PUTpatch→ PATCHdelete→ DELETE
Opinionated (CRUD):
create→ POSTread→ GETupdate→ PUTquery→ GET with optional pagination
Release 1.3.80 contains both a raw and an opinionated delete declaration with the same name. Their defaults are not uniquely addressable. For a Base-only model, define a uniquely named DELETE method type instead of relying on delete() defaults. SpringBoot users can use deleteEntity.
Example:
resource /customers as Customer[] by id {
create()
read readCustomer()
update()
query()
}3. Types
Basic:
type Greeting {
message*: String
}Complex types show up in datatype diagrams (hierarchy, references).
4. Pseudocode (optional)
CMN includes pseudocode syntax inside provided component resources. Diagram generation uses this model content to create sequence diagrams:
This is an independent Greeting follow-on, not part of the minimal one-model Quickstart.
component GreetingBackend {
provide /hello subPackage='greeting.v1' controller="GreetingV1Controller" {
read {
if 'is morning' {
[[ return 'Good Morning' ]]
} else 'is evening' {
[[ return 'Good Evening' ]]
} else {
[[ return 'Hello']]
}
}
}
}5. Layers
Layers can be defined:
core package com.example.demo
platform Baseapi package com.example.demo.api
platform BaseThe layer is available to profiles and generators, but its meaning is facility- and generator-specific. The Base diagram and OpenAPI generators in release 1.3.80 do not derive routing or diagram organisation from it. Tag-aware Java generators can use it as a source tag; see the multi-module outlet guide.
6. Summary
The Base facility allows you to:
- define types
- define REST resources
- use method types
- model processes
- generate OpenAPI and diagrams
