Skip to content

Commit ccdba59

Browse files
fix broken examples
For the Appendix C.4 example, "words" is said to not explode its values.
1 parent 48e7905 commit ccdba59

1 file changed

Lines changed: 13 additions & 9 deletions

File tree

src/oas.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1070,7 +1070,7 @@ examples:
10701070
dataValue:
10711071
page: 4
10721072
pageSize: 50
1073-
serializeValue: page=4&pageSize=50
1073+
serializedValue: page=4&pageSize=50
10741074
```
10751075
10761076
A complex parameter using `content` to define serialization, with multiple levels and types of examples shown to make the example usage options clear — note that `dataValue` is the same at both levels and does not need to be shown in both places in normal usage, but `serializedValue` is different:
@@ -1091,15 +1091,17 @@ content:
10911091
long:
10921092
type: number
10931093
examples:
1094-
dataValue:
1095-
lat: 10
1096-
long: 60
1097-
serializedValue: '{"lat":10,"long":60}'
1094+
'New York':
1095+
dataValue:
1096+
lat: 40.6
1097+
long: -73.9
1098+
serializedValue: '{"lat":40.6,"long":-73.9}'
10981099
examples:
1099-
dataValue:
1100-
lat: 10
1101-
long: 60
1102-
serializedValue: coordinates=%7B%22lat%22%3A10%2C%22long%22%3A60%7D
1100+
'New York':
1101+
dataValue:
1102+
lat: 40.6
1103+
long: -73.9
1104+
serializedValue: coordinates=%7B%22lat%22%3A40.6%2C%22long%22%3A-73.9%7D
11031105
```
11041106

11051107
A querystring parameter using regular form encoding, but managed with a Media Type Object.
@@ -1108,6 +1110,7 @@ Examples are shown at both the media type and parameter level to emphasize that,
11081110

11091111
```yaml
11101112
in: querystring
1113+
name: metadata
11111114
content:
11121115
application/x-www-form-urlencoded:
11131116
schema:
@@ -4971,6 +4974,7 @@ parameters:
49714974
type: array
49724975
items:
49734976
type: string
4977+
explode: false
49744978
```
49754979
49764980
This translates to the following URI Template:

0 commit comments

Comments
 (0)