Builder

Builder for constructing a Header instance.

Report a problem

Constructors

Link copied to clipboard
constructor(schemaInference: JsonSchemaInference)

Properties

Link copied to clipboard

Map of media type to MediaType object.

Link copied to clipboard

Marks the header as deprecated when true.

Link copied to clipboard

A brief description of the header.

Link copied to clipboard

Example of the parameter's potential value.

Link copied to clipboard

Map of examples for the parameter.

Link copied to clipboard

Specifies whether arrays and objects generate separate headers for each value.

Link copied to clipboard

Specification-extensions for this parameter (keys must start with x-).

Link copied to clipboard

Whether this header is mandatory.

Link copied to clipboard

The schema defining the header type.

Link copied to clipboard

Describes how the header value will be serialized (e.g., "matrix", "label", "form", "simple", "spaceDelimited", "pipeDelimited", "deepObject").

Functions

Link copied to clipboard
open override fun buildSchema(type: KType): JsonSchema

Builds a JsonSchema for the given type.

Link copied to clipboard
fun example(name: String, example: ExampleObject)

Adds an example for this parameter.

Link copied to clipboard
inline fun <T : Any> extension(name: String, value: T)

Adds a custom vendor-specific extension.

Link copied to clipboard
operator fun ContentType.invoke(configure: MediaType.Builder.() -> Unit = {})

Adds a media type definition for the request body.

Link copied to clipboard

Generates a JSON Schema representation for the given type T.