openAPI abstract method

Future<OpenAPIDocument> openAPI()

Get an OpenAPI documentation (API definition) for this service.

The API definition is retrieved:

  1. Get a link for the relation "service-desc".
  2. Ensure it's type is "application/vnd.oai.openapi+json".
  3. Read JSON content from a HTTP service.
  4. Decode content received as JSON Object using the standard JSON decoder.
  5. Wrap such decoded object in an OpenAPIDocument instance.

If a service does not provide an OpenAPI definition in JSON or retrieving it fails, then a ServiceException is thrown.

Most often for an OGC API Features service an API definition is an OpenAPI 3.0 document, but this is not required by the standard.

Implementation

Future<OpenAPIDocument> openAPI();