Skip to content

Commit c3cea4e

Browse files
author
Ron
authored
Merge pull request OAI#992 from MikeRalphson/CImarkdown3
[OpenAPI.next] validate (not lint) versions/3.*.md with mdv
2 parents 0c25724 + 26f54c2 commit c3cea4e

File tree

3 files changed

+19
-9
lines changed

3 files changed

+19
-9
lines changed

.travis.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,12 @@ env:
77
matrix:
88
allow_failures:
99
- env: VALIDATORS=tv4
10+
install:
11+
- rm -rf ~/.nvm
12+
- curl -L https://raw.githubusercontent.com/creationix/nvm/master/install.sh | sh
13+
- source ~/.nvm/nvm.sh
14+
- nvm install 6.1
15+
- nvm use 6.1
16+
script:
17+
- npm install
18+
- node node_modules/mdv/mdv versions/3.*.md

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
"json2yaml": "^1.0.3",
2525
"jsonschema": "^1.0.0",
2626
"map-stream": "^0.1.0",
27+
"mdv": "^1.0.3",
2728
"mocha": "^1.21.3",
2829
"q": "^1.0.1",
2930
"request": "^2.39.0",

versions/3.0.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ Types that are not accompanied by a `format` property follow their definition fr
151151
The formats defined by the OAS are:
152152

153153

154-
Common Name | [`type`](#dataTypeType) | [`format`](#dataTypeFormat) | Comments
154+
Common Name | [`type`](#dataTypes) | [`format`](#dataTypeFormat) | Comments
155155
----------- | ------ | -------- | --------
156156
integer | `integer` | `int32` | signed 32 bits
157157
long | `integer` | `int64` | signed 64 bits
@@ -663,8 +663,8 @@ Field Name | Type | Description
663663
<a name="pathItemHead"></a>head | [Operation Object](#operationObject) | A definition of a HEAD operation on this path.
664664
<a name="pathItemPatch"></a>patch | [Operation Object](#operationObject) | A definition of a PATCH operation on this path.
665665
<a name="pathItemTrace"></a>trace | [Operation Object](#operationObject) | A definition of a TRACE operation on this path.
666-
<a name="pathItemServers"></a>servers | [[Server Object](#serverObject)] | An alternative `server` array to service all operations in this path.
667-
<a name="pathItemParameters"></a>parameters | [[Parameter Object](#parameterObject) \| [Reference Object](#referenceObject)] | A list of parameters that are applicable for all the operations described under this path. These parameters can be overridden at the operation level, but cannot be removed there. The list MUST NOT include duplicated parameters. A unique parameter is defined by a combination of a [name](#parameterName) and [___location](#parameterIn). The list can use the [Reference Object](#referenceObject) to link to parameters that are defined at the [OpenAPI Object's parameters](#oasParameters).
666+
<a name="pathItemServers"></a>servers | [[Server Object](#serverObject)] | An alternative `server` array to service all operations in this path.
667+
<a name="pathItemParameters"></a>parameters | [[Parameter Object](#parameterObject) \| [Reference Object](#referenceObject)] | A list of parameters that are applicable for all the operations described under this path. These parameters can be overridden at the operation level, but cannot be removed there. The list MUST NOT include duplicated parameters. A unique parameter is defined by a combination of a [name](#parameterName) and [___location](#parameterIn). The list can use the [Reference Object](#referenceObject) to link to parameters that are defined at the [OpenAPI Object's components/parameters](#componentsParameters).
668668

669669

670670
This object can be extended with [Specification Extensions](#specificationExtensions).
@@ -763,7 +763,7 @@ Field Name | Type | Description
763763
<a name="operationDescription"></a>description | `string` | A verbose explanation of the operation behavior. [CommonMark syntax](http://spec.commonmark.org/) can be used for rich text representation.
764764
<a name="operationExternalDocs"></a>externalDocs | [External Documentation Object](#externalDocumentationObject) | Additional external documentation for this operation.
765765
<a name="operationId"></a>operationId | `string` | Unique string used to identify the operation. The id MUST be unique among all operations described in the API. Tools and libraries MAY use the operationId to uniquely identify an operation, therefore, it is recommended to follow common programming naming conventions.
766-
<a name="operationParameters"></a>parameters | [[Parameter Object](#parameterObject) \| [Reference Object](#referenceObject)] | A list of parameters that are applicable for this operation. If a parameter is already defined at the [Path Item](#pathItemParameters), the new definition will override it but can never remove it. The list MUST NOT include duplicated parameters. A unique parameter is defined by a combination of a [name](#parameterName) and [___location](#parameterIn). The list can use the [Reference Object](#referenceObject) to link to parameters that are defined at the [OpenAPI Object's parameters](#oasParameters).
766+
<a name="operationParameters"></a>parameters | [[Parameter Object](#parameterObject) \| [Reference Object](#referenceObject)] | A list of parameters that are applicable for this operation. If a parameter is already defined at the [Path Item](#pathItemParameters), the new definition will override it but can never remove it. The list MUST NOT include duplicated parameters. A unique parameter is defined by a combination of a [name](#parameterName) and [___location](#parameterIn). The list can use the [Reference Object](#referenceObject) to link to parameters that are defined at the [OpenAPI Object's components/parameters](#componentsParameters).
767767
<a name="operationRequestBody"></a>requestBody | [Request Body Object](#requestBodyObject) \| [Reference Object](#referenceObject) | The request body applicable for this operation. The `requestBody` is only supported in HTTP methods where the [HTTP 1.1 specification](https://tools.ietf.org/html/rfc7231#section-4.3.1) has explicitly defined semantics for request bodies. In other cases where the HTTP spec is vague, `requestBody` SHALL be ignored by consumers.
768768
<a name="operationResponses"></a>responses | [Responses Object](#responsesObject) | **Required.** The list of possible responses as they are returned from executing this operation.
769769
<a name="operationCallbacks"></a>callbacks | [Callbacks Object](#callbacksObject) | The list of possible callbacks as they are returned from executing this operation.
@@ -957,7 +957,7 @@ Field Name | Type | Description
957957

958958
In order to support common ways of serializing simple parameters, a set of `style` values are defined.
959959

960-
`style` | [`type`](#dataTypeType) | `in` | Comments
960+
`style` | [`type`](#dataTypes) | `in` | Comments
961961
----------- | ------ | -------- | --------
962962
matrix | `primitive`, `array`, `object` | `path` | Path-style parameters defined by [RFC6570](https://tools.ietf.org/html/rfc6570#section-3.2.7)
963963
label | `primitive`, `array`, `object` | `path` | Label style parameters defined by [RFC6570](https://tools.ietf.org/html/rfc6570#section-3.2.5)
@@ -1230,7 +1230,7 @@ content:
12301230

12311231
#### <a name="contentObject"></a>Content Object
12321232

1233-
Describes a set of supported media types. A Content Object can be used in [Request Body Object](#requestBody),
1233+
Describes a set of supported media types. A Content Object can be used in [Request Body Object](#requestBodyObject),
12341234
[Parameter Objects](#parameterObject), [Header Objects](#headerObject), and [Response Objects](#responseObject).
12351235

12361236
Each key in the Content Object is the media type of the [Media Type Object](#mediaTypeObject).
@@ -1587,12 +1587,12 @@ SHOULD be the response for a successful operation call.
15871587
##### Fixed Fields
15881588
Field Name | Type | Description
15891589
---|:---:|---
1590-
<a name="responsesDefault"></a>default | [Response Object](#responseObject) \| [Reference Object](#referenceObject) | The documentation of responses other than the ones declared for specific HTTP response codes. It can be used to cover undeclared responses. [Reference Object](#referenceObject) can be used to link to a response that is defined at the [OpenAPI Object's responses](#oasResponses) section.
1590+
<a name="responsesDefault"></a>default | [Response Object](#responseObject) \| [Reference Object](#referenceObject) | The documentation of responses other than the ones declared for specific HTTP response codes. It can be used to cover undeclared responses. [Reference Object](#referenceObject) can be used to link to a response that is defined at the [OpenAPI Object's components/responses](#componentsResponses) section.
15911591

15921592
##### Patterned Fields
15931593
Field Pattern | Type | Description
15941594
---|:---:|---
1595-
<a name="responsesCode"></a>[HTTP Status Code](#httpCodes) | [Response Object](#responseObject) \| [Reference Object](#referenceObject) | Any [HTTP status code](#httpCodes) can be used as the property name (one property per HTTP status code). Describes the expected response for that HTTP status code. [Reference Object](#referenceObject) can be used to link to a response that is defined at the [OpenAPI Object's responses](#oasResponses) section. This field MUST be quoted for compatibility between JSON and YAML (i.e. '200'), and MAY contain the uppercase character, `X` to designate a wildcard, such as `2XX` to represent all response codes between `[200-299]`. If a response range is defined, and an explicit code within that range is defined as well, the explicit code definition takes precedence over the range definition for that code.
1595+
<a name="responsesCode"></a>[HTTP Status Code](#httpCodes) | [Response Object](#responseObject) \| [Reference Object](#referenceObject) | Any [HTTP status code](#httpCodes) can be used as the property name (one property per HTTP status code). Describes the expected response for that HTTP status code. [Reference Object](#referenceObject) can be used to link to a response that is defined at the [OpenAPI Object's components/responses](#componentsResponses) section. This field MUST be quoted for compatibility between JSON and YAML (i.e. "200"), and MAY contain the uppercase character, `X` to designate a wildcard, such as `2XX` to represent all response codes between `[200-299]`. If a response range is defined, and an explicit code within that range is defined as well, the explicit code definition takes precedence over the range definition for that code.
15961596

15971597

15981598
This object can be extended with [Specification Extensions](#specificationExtensions).
@@ -1778,7 +1778,7 @@ The key value used to identify the callback object is an expression, evaluated a
17781778
##### Patterned Fields
17791779
Field Pattern | Type | Description
17801780
---|:---:|---
1781-
<a name="callbackName"></a>{name} | [Callback Object](#callbackObject) \| [Reference Object](#ReferenceObject) | A Callback Object used to define a callback request and expected responses
1781+
<a name="callbackName"></a>{name} | [Callback Object](#callbackObject) \| [Reference Object](#referenceObject) | A Callback Object used to define a callback request and expected responses
17821782

17831783
This object can be extended with [Specification Extensions](#specificationExtensions).
17841784

0 commit comments

Comments
 (0)