Skip to content

Commit 2e78582

Browse files
authored
[ToC] Update to use internal anchors
This updates the ToC through the [Info Object](#infoObject) and its children to use the internal anchors in the document (instead of GitHub-generated anchors) Signed-off-by: Rob Dolin <[email protected]>
1 parent 529548a commit 2e78582

File tree

1 file changed

+24
-21
lines changed

1 file changed

+24
-21
lines changed

versions/3.0.md

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,20 @@ Additional utilities can also take advantage of the resulting files, such as tes
1717
## Table of Contents
1818
<!-- TOC depthFrom:1 depthTo:3 withLinks:1 updateOnSave:1 orderedList:0 -->
1919

20-
- [Revision History](#revision-history)
2120
- [Definitions](#definitions)
21+
- [Path Templating](#pathTemplating)
22+
- [Media Types](#mediaTypes)
23+
- [HTTP Status Codes](#httpCodes)
2224
- [Specification](#specification)
2325
- [Format](#format)
24-
- [File Structure](#file-structure)
25-
- [Data Types](#data-types)
26-
- [Relative References In Urls](#relativeReferences)
26+
- [File Structure](#fileStructure)
27+
- [Data Types](#dataTypes)
28+
- [Relative References In Urls](#relativeReferences)
2729
- [Schema](#schema)
28-
- [OpenAPI Object](#openapi-object)
29-
- [Info Object](#info-object)
30-
- [Contact Object](#contact-object)
31-
- [License Object](#license-object)
30+
- [OpenAPI Object](#oasObject)
31+
- [Info Object](#infoObject)
32+
- [Contact Object](#contactObject)
33+
- [License Object](#licenseObject)
3234
- [Server Object](#server-object)
3335
- [Components Object](#components-object)
3436
- [Paths Object](#paths-object)
@@ -62,21 +64,11 @@ Additional utilities can also take advantage of the resulting files, such as tes
6264
- [Security Requirement Object](#security-requirement-object)
6365
- [Specification Extensions](#specification-extensions)
6466
- [Security Filtering](#security-filtering)
67+
- [Appendix A: Revision History](#revisionHistory)
6568

6669

6770
<!-- /TOC -->
6871

69-
## Revision History
70-
71-
Version | Date | Notes
72-
--- | --- | ---
73-
3.0.0-rc0 | 2017-02-28 | Implementor's draft of the 3.0 specification
74-
2.0 | 2015-12-31 | Donation of Swagger 2.0 to the Open API Initiative
75-
2.0 | 2014-09-08 | Release of Swagger 2.0
76-
1.2 | 2014-03-14 | Initial release of the formal document.
77-
1.1 | 2012-08-22 | Release of Swagger 1.1
78-
1.0 | 2011-08-10 | First release of the Swagger Specification
79-
8072
## Definitions
8173

8274
##### <a name="pathTemplating"></a>Path Templating
@@ -130,15 +122,15 @@ In order to preserve the ability to round-trip between YAML and JSON formats, YA
130122
- Tags MUST be limited to those allowed by the [JSON Schema ruleset](http://www.yaml.org/spec/1.2/spec.html#id2803231)
131123
- Keys used in YAML maps MUST be limited to a scalar string, as defined by the [YAML Failsafe schema ruleset](http://yaml.org/spec/1.2/spec.html#id2802346)
132124

133-
### File Structure
125+
### <a name="fileStructure"></a>File Structure
134126

135127
The OAS representation of the API is made of a single file.
136128
However, parts of the definitions can be split into separate files, at the discretion of the user.
137129
This is applicable for `$ref` fields in the specification as follows from the [JSON Schema](http://json-schema.org) definitions.
138130

139131
By convention, the OpenAPI Specification (OAS) file is named `openapi.json` or `openapi.yaml`.
140132

141-
### Data Types
133+
### <a name="dataTypes"></a>Data Types
142134

143135
Primitive data types in the OAS are based on the types supported by the [JSON Schema Specification Wright Draft 00](https://tools.ietf.org/html/draft-wright-json-schema-00#section-4.2). Note that `integer` as a type is also supported and is defined as a JSON number without a fraction or exponent part. `null` is not supported as a value.
144136
Models are described using the [Schema Object](#schemaObject) which is an extended subset of JSON Schema Specification Wright Draft 00.
@@ -3550,3 +3542,14 @@ Two examples for this:
35503542

35513543
1. The [Paths Object](#pathsObject) MAY be empty. It may be counterintuitive, but this may tell the viewer that they got to the right place, but can't access any documentation. They'd still have access to the [Info Object](#infoObject) which may contain additional information regarding authentication.
35523544
2. The [Path Item Object](#pathItemObject) MAY be empty. In this case, the viewer will be aware that the path exists, but will not be able to see any of its operations or parameters. This is different than hiding the path itself from the [Paths Object](#pathsObject) so the user will not be aware of its existence. This allows the documentation provider a finer control over what the viewer can see.
3545+
3546+
## <a name="revisionHistory"></a>Appendix A: Revision History
3547+
3548+
Version | Date | Notes
3549+
--- | --- | ---
3550+
3.0.0-rc0 | 2017-02-28 | Implementor's draft of the 3.0 specification
3551+
2.0 | 2015-12-31 | Donation of Swagger 2.0 to the Open API Initiative
3552+
2.0 | 2014-09-08 | Release of Swagger 2.0
3553+
1.2 | 2014-03-14 | Initial release of the formal document.
3554+
1.1 | 2012-08-22 | Release of Swagger 1.1
3555+
1.0 | 2011-08-10 | First release of the Swagger Specification

0 commit comments

Comments
 (0)