You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: draft-release-notes.md
+31-9Lines changed: 31 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,15 @@ What's coming up? Look at `src/oas.md` on the relevant development branch for fu
16
16
-`kind` to allow multiple categories of tag. The `kind` field is free-form text, however there are some expected/conventional values such as `nav` (in line with the most common current usage as grouping for documentation output).
17
17
- A [registry](https://spec.openapis.org/registry/tag-kind/index.html) to establish conventions for values used in `kind`.
18
18
19
+
### Document identity and URL resolution
20
+
21
+
- Additional top-level field `$self` is added to allow users to define the base URI of the document, used to resolve relative references.
22
+
If no `$self` field is defined, then the retrieval URI is used - just as it was in previous versions of OpenAPI.
23
+
- Other URL/URI handling does not change between 3.1 and 3.2 (but bears a recap in case you're wondering how it all goes together):
24
+
- Other URLs, such as to external documentation or a license, are resolved against the base URI.
25
+
- Relative links inside `description` fields are resolved relative to their rendered context, such as your published API documentation page.
26
+
- API endpoints are resolved against the URL in the Server Object, which itself might be relative and resolved against the base URI.
27
+
19
28
### Updated security schemes
20
29
21
30
- Support for OAuth2 Device Authorization flow with additional `deviceAuthorization` field in the `flows` object and for the individual flow, a new field `deviceAuthorizationUrl` alongside `tokenUrl`.
@@ -27,7 +36,7 @@ What's coming up? Look at `src/oas.md` on the relevant development branch for fu
27
36
28
37
- Clarify that server URLs should not include fragment or query.
29
38
- Support new `name` field alongside `description`, `url` and `variables`.
30
-
- Formal path templating support for variable substitution in server urls.
39
+
- Formal path templating support for variable substitution in server urls, alongside guidance that each variable can only be used once in a URL.
31
40
32
41
### Better polymorphic support
33
42
@@ -37,10 +46,6 @@ What's coming up? Look at `src/oas.md` on the relevant development branch for fu
37
46
- No change from previous versions: use `mapping` to link the discriminator property value to the Schema name if they aren't an exact match.
38
47
- Implementations now SHOULD (rather than MAY) support templates/generics using `$dynamicRef`.
39
48
40
-
### Reference resolution
41
-
42
-
Additional top-level `$self` to be used as a base URI for resolving references in the OpenAPI description. If not present, the existing/earlier behaviour of using the retrieval URL as a base applies.
43
-
44
49
### Path templating
45
50
46
51
**ABNF** (Augmented Backus–Naur Form) formalised for path templating, server variables, and runtime expressions in the Links object.
@@ -52,12 +57,12 @@ Additional top-level `$self` to be used as a base URI for resolving references i
52
57
-`wrapped: true` deprecated in favor of `nodeType: element` (as `nodeType` defaults to `none` for arrays to preserve compatibility).
53
58
- The `xml` keyword can be used in any Schema Object.
54
59
- XML namespaces can be IRIs (rather than URIs).
55
-
- Explanation and example on how to handle `null` in XML.
60
+
- Explanation and examples for many use cases including handling `null`, handling arrays, replacing the name, and handling ordered elements.
56
61
- Clarify that the root schema of an XML object should use the component name.
57
62
58
63
### Support for sequential media types
59
64
60
-
- Support for sequential media types such as `text/event-stream` for server-sent events (SSE) and `application/jsonl`, `application/json-seq` and others for sequential data.
65
+
- Support for sequential media types such as `text/event-stream` for server-sent events (SSE) and `multipart/mixed`, `application/jsonl`, `application/json-seq` and others for sequential data.
61
66
- Responses can be a repeating data structure, and are treated as if they are an array of schema objects.
62
67
- Use `itemSchema` in a mediatype entry to describe each item.
63
68
- Related: a new media types registry is published to give more context for each of the media types.
@@ -69,6 +74,19 @@ Additional top-level `$self` to be used as a base URI for resolving references i
69
74
- Parameters can therefore be `in` the `querystring` as an alternative to the existing `header`, `cookie`, `query` and `path` values.
70
75
-`allowReserved` field is now permitted on headers and on parameters with any value of `in`.
71
76
- Remove incorrect mention of Reference Object in the header `schema` field. The JSONSchema ref would be the correct thing to use in this context.
77
+
- The `examples` (and older `example`) field is now supported with `content`.
78
+
79
+
### Show examples in both structure and serialized forms
80
+
81
+
- The Example Object (used in `examples` fields) gets two new fields: `dataValue` and `serializedValue`.
82
+
-`dataValue` describes the example in structured format.
83
+
-`serializedValue` shows how the example will be formatted when it is sent/received by the API.
84
+
- The existing `value` field can still be used, which means that you can safely upgrade to 3.2 and then revisit these fields and update them to use either `dataValue` or `serializedValue` as appropriate.
85
+
Use the new fields for examples you add after upgrading to 3.2.
86
+
- The existing `externalValue` field can still be used to give a reference to an example, but this is now clearly documented as being a serialized value.
87
+
- There are lots of examples of the examples (ha!) and clear documentation of how the fields can be combined.
88
+
- Summary of what to do: use `examples` over `example`, and use `dataValue` to show a clear, structured example of the data.
89
+
If your use case could benefit from an example of how the data will look when it's transmitted, use `serializedValue` as well.
72
90
73
91
### Flexible response metadata fields
74
92
@@ -78,7 +96,9 @@ Additional top-level `$self` to be used as a base URI for resolving references i
78
96
### Minor edits that are worth a mention
79
97
80
98
- Streamlined to YAML examples (unless something specific to another format) to try to make it easier to follow.
81
-
- Non-Schema examples no longer "override" Schema examples; tools are free to use the most appropriate example for any given use case
99
+
- Non-Schema examples no longer "override" Schema examples; tools are free to use the most appropriate example for any given use case.
100
+
- A new key `mediaTypes` is supported under `components` to support re-use of Media Type Objects.
101
+
82
102
### In-place updates to existing specifications and standards that we reference
83
103
84
104
- Update to <https://www.ietf.org/archive/id/draft-bhutton-json-schema-01.html> of JSON Schema Specification.
@@ -89,10 +109,12 @@ Additional top-level `$self` to be used as a base URI for resolving references i
89
109
### Editorial changes
90
110
91
111
- Extensive additions around media types, encoding, sequential media types, SSE examples, working with binary data.
92
-
- Clarification that Example Objects can be used in Header Objects.
93
112
- Better explanation and examples for using Encoding.
94
113
- Clarify that Request Body Objects need to specify at least one media type to be meaningful.
95
114
- How to more clearly indicate that responses will not have a body.
115
+
- Explanation and examples of headers including `Link` and `Set-Cookie`.
116
+
- No change but extensive additional notes on parsing and serializing JSON and non-JSON data formats.
117
+
Particularly if you are buildling OpenAPI tooling, this section gives much better guidance on some of those tricky edge cases.
0 commit comments