api

http4k / org.http4k.contract.openapi.v3 / OpenApi3

OpenApi3

class OpenApi3<NODE : Any> : ContractRenderer, ErrorResponseRenderer

Contract renderer for OpenApi3 format JSON. For the JSON schema generation, naming of object models will default to either reflective or hashcode based depending on if a Auto Json is passed.

Constructors

Name Summary
<init> OpenApi3(apiInfo: ApiInfo, json: AutoMarshallingJson<NODE>, extensions: List<OpenApiExtension> = emptyList())
Contract renderer for OpenApi3 format JSON. For the JSON schema generation, naming of object models will default to either reflective or hashcode based depending on if a Auto Json is passed.OpenApi3(apiInfo: ApiInfo, json: Json<NODE>, extensions: List<OpenApiExtension> = emptyList(), apiRenderer: ApiRenderer<Api<NODE>, NODE> = OpenApi3ApiRenderer(json), securityRenderer: SecurityRenderer = OpenApi3SecurityRenderer, errorResponseRenderer: ErrorResponseRenderer = JsonErrorResponseRenderer(json))

Functions

Name Summary
description fun description(contractRoot: PathSegments, security: Security?, routes: List<ContractRoute>): Response