|
208 | 208 | </t> |
209 | 209 | <t> |
210 | 210 | Among these, this specification defines the "application/schema-instance+json" |
211 | | - media type which defines handling for fragments in the URI, |
212 | | - and the "schema" media type parameter. |
| 211 | + media type which defines handling for fragments in the URI. |
213 | 212 | </t> |
214 | 213 |
|
215 | 214 | <section title="Instance Data Model"> |
|
305 | 304 | A schema can itself be interpreted as an instance, but SHOULD always be given |
306 | 305 | the media type "application/schema+json" rather than |
307 | 306 | "application/schema-instance+json". The "application/schema+json" media |
308 | | - type is defined to offer a superset of the media type parameter and |
| 307 | + type is defined to offer a superset of the |
309 | 308 | fragment identifier syntax and semantics provided by |
310 | 309 | "application/schema-instance+json". |
311 | 310 | </t> |
|
2007 | 2006 |
|
2008 | 2007 | </section> |
2009 | 2008 |
|
2010 | | - |
2011 | | - <section title='Identifying a Schema via a Media Type Parameter' anchor="parameter"> |
2012 | | - <t> |
2013 | | - Media types MAY allow for a "schema" media type parameter, which gives |
2014 | | - HTTP servers the ability to perform Content-Type Negotiation based on schema. |
2015 | | - The media-type parameter MUST be a whitespace-separated list of URIs |
2016 | | - (i.e. relative references are invalid). |
2017 | | - </t> |
2018 | | - <t> |
2019 | | - When using the media type application/schema-instance+json, the "schema" |
2020 | | - parameter MUST be supplied. |
2021 | | - </t> |
2022 | | - <t> |
2023 | | - When using the media type application/schema+json, the "schema" parameter |
2024 | | - MAY be supplied. If supplied, it SHOULD contain the same URI as identified |
2025 | | - by the "$schema" keyword, and MAY contain additional URIs. The "$schema" |
2026 | | - URI MUST be considered the schema's canonical meta-schema, regardless |
2027 | | - of the presence of alternative or additional meta-schemas as a media type |
2028 | | - parameter. |
2029 | | - </t> |
2030 | | - <t> |
2031 | | - The schema URI is opaque and SHOULD NOT automatically be dereferenced. |
2032 | | - If the implementation does not understand the semantics of the provided schema, |
2033 | | - the implementation can instead follow the "describedby" links, if any, which may |
2034 | | - provide information on how to handle the schema. |
2035 | | - Since "schema" doesn't necessarily point to a network location, the |
2036 | | - "describedby" relation is used for linking to a downloadable schema. |
2037 | | - However, for simplicity, schema authors should make these URIs point to the same |
2038 | | - resource when possible. |
2039 | | - </t> |
2040 | | - |
2041 | | - <t> |
2042 | | - In HTTP, the media-type parameter would be sent inside the Content-Type header: |
2043 | | - </t> |
2044 | | - |
2045 | | - <figure> |
2046 | | - <artwork> |
2047 | | - <![CDATA[ |
2048 | | - Content-Type: application/schema-instance+json; |
2049 | | - schema="https://example.com/my-hyper-schema" |
2050 | | - ]]> |
2051 | | - </artwork> |
2052 | | - </figure> |
2053 | | - |
2054 | | - <t> |
2055 | | - Multiple schemas are whitespace separated, and indicate that the |
2056 | | - instance conforms to all of the listed schemas: |
2057 | | - </t> |
2058 | | - |
2059 | | - <figure> |
2060 | | - <artwork> |
2061 | | - <![CDATA[ |
2062 | | - Content-Type: application/schema-instance+json; |
2063 | | - schema="https://example.com/alice https://example.com/bob" |
2064 | | - ]]> |
2065 | | - </artwork> |
2066 | | - </figure> |
2067 | | - |
2068 | | - <t> |
2069 | | - Media type parameters are also used in HTTP's Accept request header: |
2070 | | - </t> |
2071 | | - |
2072 | | - <figure> |
2073 | | - <artwork> |
2074 | | - <![CDATA[ |
2075 | | - Accept: application/schema-instance+json; |
2076 | | - schema="https://example.com/qiang https://example.com/li", |
2077 | | - application/schema-instance+json; |
2078 | | - schema="https://example.com/kumar" |
2079 | | - ]]> |
2080 | | - </artwork> |
2081 | | - </figure> |
2082 | | - |
2083 | | - <t> |
2084 | | - As with Content-Type, multiple schema parameters in the same string |
2085 | | - requests an instance that conforms to all of the listed schemas. |
2086 | | - </t> |
2087 | | - |
2088 | | - <t> |
2089 | | - Unlike Content-Type, Accept can contain multiple values to |
2090 | | - indicate that the client can accept several media types. |
2091 | | - In the above example, note that the two media types differ |
2092 | | - only by their schema parameter values. This requests an |
2093 | | - application/schema-instance+json representation that conforms to at least one |
2094 | | - of the identified schemas. |
2095 | | - </t> |
2096 | | - |
2097 | | - <t> |
2098 | | - <cref> |
2099 | | - This paragraph assumes that we can register a "schema" link relation. |
2100 | | - Should we instead specify something like "tag:json-schema.org,2017:schema" |
2101 | | - for now? |
2102 | | - </cref> |
2103 | | - HTTP can also send the "schema" in a Link, though this may impact media-type |
2104 | | - semantics and Content-Type negotiation if this replaces the media-type parameter |
2105 | | - entirely: |
2106 | | - </t> |
2107 | | - |
2108 | | - <figure> |
2109 | | - <artwork> |
2110 | | - <![CDATA[ |
2111 | | - Link: </alice>;rel="schema", </bob>;rel="schema" |
2112 | | - ]]> |
2113 | | - </artwork> |
2114 | | - </figure> |
2115 | | - |
2116 | | - </section> |
2117 | | - |
2118 | 2009 | <section title="Usage Over HTTP"> |
2119 | 2010 | <t> |
2120 | 2011 | When used for hypermedia systems over a network, |
@@ -3954,7 +3845,7 @@ https://example.com/schemas/common#/$defs/count/minimum |
3954 | 3845 | <t>$dynamic* (previously $recursive) no longer use runtime base URI determination</t> |
3955 | 3846 | <t>Define Compound Schema Documents (bundle) and processing</t> |
3956 | 3847 | <t>Reference ECMA-262, 11th edition for regular expression support</t> |
3957 | | - <t></t> |
| 3848 | + <t>Remove media type parameters</t> |
3958 | 3849 | <t></t> |
3959 | 3850 | <t></t> |
3960 | 3851 | </list> |
|
0 commit comments