Custom entities let a site builder add content types of their own, with fields, listings, URLs and links between them, and deliver a whole application without framework code. Start with the test for when a custom entity beats a page, then define one: its identifier, paths, layout and switches, and which of them you can change once records exist.

The middle of the unit is the domain model. Relationships between records get the most space, because they are what turns a flat list into a model; parent and child records are the other way records connect, with the rule for choosing between the two. Then come the templates: the listing and detail routes a definition gets, and querying records from any other template. The page on the API, GraphQL and MCP shows the same records to a headless front end or an agent, and the unit ends with a learning site built from all of it.