Definition kinds
A service definition carried by a registry advertises what family and version of definition it is via a kind: a string of the form<identifier>@<version>.
Examples:
openapi@3.0, openapi@3.1, asyncapi@2.
Kinds live on the definition side only:
- In a registry definitions browse entry, as the optional
kindfield. - In a registry definition descriptor (the versioned JSON the entry’s
sourceresolves to), as the optionalkindfield on each version entry.
Version ranges in this document follow semver
notation as implemented by the semver package used by the host.
Adapter compatibility
An adapter module may declare acompatibility list in its module.json
manifest (see Modules):
compatibility is optional and only meaningful for adapter modules
(environment modules ignore it). An empty or absent list means “declares no
kinds”: the adapter is still installable, it just won’t be offered as a
default for any kind.
How compatibility is checked
- The definition’s
kindis parsed into{ identifier, version }. - The kind version is normalized to full semver: a
k-part version is padded to three parts (3→3.0.0,3.1→3.1.0). - The adapter is compatible if any compatibility entry matches the
identifier and
satisfies(normalizedVersion, entry.version)is true.
openapi@3.0 (normalized to 3.0.0) is
accepted by an adapter declaring openapi with >=3.0 <4.0, but not by
one declaring >=3.1 <4.0.
Resolving an adapter for install
GET /services/install/adapters?kind=<kind> returns every installed adapter
module, ranked so compatible adapters sort ahead of incompatible ones, and
within each compatibility group active adapters (and then built-in / canonical
adapters) sort ahead of inactive / third-party ones (ties broken by name). The
default field is the top-ranked adapter that is both compatible and active
(or null when none qualifies).
kind query parameter to receive every adapter unranked (the default
field is null); this is how a client discovers what is installed before the
user has chosen a definition.
Install behavior
POST /services/install resolves the adapter as follows:
- An explicit
adapterin the request body always wins: even an adapter whosecompatibilitydoes not match the definitionkind. This lets users force an install with an unconventional adapter. - Otherwise, the server looks up the definition’s
kind(from the registry descriptor) and selects the default ranked adapter - the compatible and active one; built-in (canonical) adapters win ties. - If neither yields an adapter and no compatible+active adapter exists, the
request fails with
400.
adapter.generateDefinition. It is unrelated to the definition
kind: kind describes the definition, adapter selects the module.
Built-in adapters
The built-inopenapi adapter accepts the openapi family for the 3.x
range (>=3.0 <4.0), since the generator supports OpenAPI 3.0.x and 3.1.x.