Encoding

data class Encoding(val contentType: ContentType, val headers: Map<String, ReferenceOr<Header>>? = null, val style: String? = null, val explode: Boolean? = null, val allowReserved: Boolean? = null, val extensions: ExtensionProperties? = null) : Extensible(source)

A single encoding definition applied to a single schema property.

Report a problem

Constructors

Link copied to clipboard
constructor(contentType: ContentType, headers: Map<String, ReferenceOr<Header>>? = null, style: String? = null, explode: Boolean? = null, allowReserved: Boolean? = null, extensions: ExtensionProperties? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Determines whether the parameter value SHOULD allow reserved characters, as defined by RFC3986 :/?#[]@!$&'()*+,;= to be included without percent-encoding. The default value is false. This property SHALL be ignored if the request body media type is not application/x-www-form-urlencoded.

Link copied to clipboard

The Content-Type for encoding a specific property. Default value depends on the property type:

Link copied to clipboard

When this is true, property values of type array or object generate separate parameters for each value of the array, or key-value-pair of the map. For other types of properties this property has no effect. When style is form, the default value is true. For all other styles, the default value is false. This property SHALL be ignored if the request body media type is not application/x-www-form-urlencoded.

Link copied to clipboard
open override val extensions: ExtensionProperties?

Any additional external documentation for this OpenAPI document. The key is the name of the extension (beginning with x-), and the value is the data. The value can be a JsonNull, JsonPrimitive, JsonArray or JsonObject.

Link copied to clipboard

A map allowing additional information to be provided as headers, for example Content-Disposition. Content-Type is described separately and SHALL be ignored in this section. This property SHALL be ignored if the request body media type is not a multipart

Link copied to clipboard

Describes how a specific property value will be serialized depending on its type. See Style for details on the style property. The behavior follows the same values as query parameters, including default values. This property SHALL be ignored if the request body media type is not application/x-www-form-urlencoded.