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: schemas/v3.0/README.md
+20-4Lines changed: 20 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,4 @@
1
-
OpenAPI 3.0.X JSON Schema
2
-
---
1
+
# OpenAPI 3.0.X JSON Schema
3
2
4
3
This directory contains the YAML source for generating the JSON Schema for validating OpenAPI definitions of versions 3.0.X, which is published on [https://spec.openapis.org](https://spec.openapis.org).
5
4
@@ -12,16 +11,33 @@ The source in this directory, which has `WORK-IN-PROGRESS` in its `id`, is _not
12
11
The published schemas on the spec site have an _iteration date_ in their `id`s.
13
12
This allows the schemas for a release line (in this case 3.0) to be updated independent of the spec patch release cycle.
14
13
15
-
The iteration version of the JSON Schema can be found in the `id` field. For example, the value of `id: https://spec.openapis.org/oas/3.0/schema/2019-04-02` means this iteration was created on April 2nd, 2019.
14
+
The iteration version of the JSON Schema can be found in the `id` field.
15
+
For example, the value of `id: https://spec.openapis.org/oas/3.0/schema/2019-04-02` means this iteration was created on April 2nd, 2019.
16
16
17
17
The special URL with `latest` in place of the date is intended to provide an HTTP redirect to the most recent dated schema.
18
18
19
19
## Improving the schema
20
20
21
-
As a reminder, the JSON Schema is not the source of truth for the Specification. In cases of conflicts between the Specification itself and the JSON Schema, the Specification wins. Also, some Specification constraints cannot be represented with the JSON Schema so it's highly recommended to employ other methods to ensure compliance.
21
+
As a reminder, the JSON Schema is not the source of truth for the Specification.
22
+
In cases of conflicts between the Specification itself and the JSON Schema, the Specification wins.
23
+
Also, some Specification constraints cannot be represented with the JSON Schema so it's highly recommended to employ other methods to ensure compliance.
22
24
23
25
The schema only validates the mandatory aspects of the OAS.
24
26
Validating requirements that are optional, or field usage that has undefined or ignored behavior are not within the scope of this schema.
25
27
Schemas to perform additional optional validation are [under consideration](https://github.com/OAI/OpenAPI-Specification/issues/4141).
26
28
27
29
Improvements can be submitted by opening a PR against the `main` branch.
30
+
31
+
Modify the `schema.yaml` file and add test cases for your changes.
32
+
33
+
The TSC will then:
34
+
- Run tests on the updated schema
35
+
- Update the iteration version
36
+
- Publish the new version
37
+
38
+
The [test suite](../../tests/v3.0) is part of this package.
0 commit comments