Open API
Open API support was introduced in version 7.0 of the Genesis platform.
The Genesis Platform uses Open API to integrate with external systems.
Genesis makes this easy to configure and set up, and an Open API specification is generated for the following resources:
- Request Server
- The specification is generated for every GPAL requestReply
codeblock
.
- The specification is generated for every GPAL requestReply
- Event Handler
- The specification is generated for each GPAL
eventHandler
codeblock.
- The specification is generated for each GPAL
- Custom Endpoints
- The specification is generated for each GPAL Custom Endpoints.
- The standard specification can be augmented using the
openapi { ... }
DSL, described in our Advanced page.
Internally, the framework uses a metadata system to generate JSON schemas for input and return objects in the Open API spec. For more details, see our pages on Network messages - type-safe messages and metadata annotations.
Accessing the Open API specification
Genesis Open API supports Open API version 3.1.
All requests to the rest endpoints below need to be authenticated.
The Open API specification is generated at runtime and is available at the following endpoints:
Full specification:
https://{server-host}/gwf/open-api/spec/
Service specific specification:
https://{server-host}/gwf/open-api/spec/{service-name}
You can verify the specification by copying the contents into Swagger Editor
For an example specification, see here.