org.openapis.v3.MediaType2.1.2
- Module URI:
- package://pkg.pkl-lang.org/pkl-pantry/org.openapis.v3@2.1.2#/MediaType.pklcontent_copy
- Source code:
- MediaType.pkl
Properties( )
-
-
-
link
Example of the parameter's potential value. The example SHOULD match the specified schema and encoding properties if present. The example field is mutually exclusive of the examples field. Furthermore, if referencing a schema that contains an example, the example value SHALL override the example provided by the schema. To represent examples of media types that cannot naturally be represented in JSON or YAML, a string value can contain the example with escaping where necessary.
-
link
Examples of the parameter's potential value. Each example SHOULD contain a value in the correct format as specified in the parameter encoding. The examples field is mutually exclusive of the example field. Furthermore, if referencing a schema that contains an example, the examples value SHALL override the example provided by the schema.
-
link
A map between a property name and its encoding information. The key, being the property name, MUST exist in the schema as a property. The encoding object SHALL only apply to requestBody objects when the media type is multipart or application/x-www-form-urlencoded.
Methods( )
Type Aliases
-
linktypealiasMediaTypeName = "application/json"|"application/xml"|"application/x-www-form-urlencoded"|"multipart/form-data"|"text/plain; charset=utf-8"|"text/html"|StringSource
Common media types that are used with OpenAPI specs.
Each Media Type Object provides schema and examples for the media type identified by its key.