rapipdf 2.2.1 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (175) hide show
  1. package/README.md +66 -14
  2. package/dist/chunks/generate-BQLGaRvK.js +386 -0
  3. package/dist/chunks/generate-BQLGaRvK.js.LICENSE.txt +224 -0
  4. package/dist/chunks/localize-CRvDVkIz.js +8 -0
  5. package/dist/node.js +13096 -0
  6. package/dist/node.js.LICENSE.txt +195 -0
  7. package/dist/rapipdf-min.js +352 -90
  8. package/dist/rapipdf-min.js.LICENSE.txt +224 -0
  9. package/dist/rapipdf.js +69 -0
  10. package/package.json +58 -52
  11. package/src/node.d.ts +82 -0
  12. package/src/rapipdf.d.ts +50 -0
  13. package/.babelrc +0 -11
  14. package/.eslintrc +0 -28
  15. package/dist/index.html +0 -7
  16. package/dist/index.html.gz +0 -0
  17. package/dist/rapipdf-min.js.gz +0 -0
  18. package/dist/rapipdf-min.js.map +0 -1
  19. package/dist/rapipdf-min.js.map.gz +0 -0
  20. package/dist/report.html +0 -53
  21. package/docs/api.html +0 -285
  22. package/docs/examples/example1.html +0 -68
  23. package/docs/examples/list.html +0 -27
  24. package/docs/examples/rapidoc-regular.woff2 +0 -0
  25. package/docs/examples/rapidoc-semi-bold.woff2 +0 -0
  26. package/docs/examples/roboto-mono-bold.woff2 +0 -0
  27. package/docs/examples/roboto-mono-regular.woff2 +0 -0
  28. package/docs/highlight/CHANGES.md +0 -1803
  29. package/docs/highlight/LICENSE +0 -24
  30. package/docs/highlight/README.md +0 -188
  31. package/docs/highlight/README.ru.md +0 -142
  32. package/docs/highlight/highlight.pack.js +0 -2
  33. package/docs/highlight/styles/a11y-dark.css +0 -99
  34. package/docs/highlight/styles/a11y-light.css +0 -99
  35. package/docs/highlight/styles/agate.css +0 -108
  36. package/docs/highlight/styles/an-old-hope.css +0 -89
  37. package/docs/highlight/styles/androidstudio.css +0 -66
  38. package/docs/highlight/styles/arduino-light.css +0 -88
  39. package/docs/highlight/styles/arta.css +0 -73
  40. package/docs/highlight/styles/ascetic.css +0 -45
  41. package/docs/highlight/styles/atelier-cave-dark.css +0 -83
  42. package/docs/highlight/styles/atelier-cave-light.css +0 -85
  43. package/docs/highlight/styles/atelier-dune-dark.css +0 -69
  44. package/docs/highlight/styles/atelier-dune-light.css +0 -69
  45. package/docs/highlight/styles/atelier-estuary-dark.css +0 -84
  46. package/docs/highlight/styles/atelier-estuary-light.css +0 -84
  47. package/docs/highlight/styles/atelier-forest-dark.css +0 -69
  48. package/docs/highlight/styles/atelier-forest-light.css +0 -69
  49. package/docs/highlight/styles/atelier-heath-dark.css +0 -69
  50. package/docs/highlight/styles/atelier-heath-light.css +0 -69
  51. package/docs/highlight/styles/atelier-lakeside-dark.css +0 -69
  52. package/docs/highlight/styles/atelier-lakeside-light.css +0 -69
  53. package/docs/highlight/styles/atelier-plateau-dark.css +0 -84
  54. package/docs/highlight/styles/atelier-plateau-light.css +0 -84
  55. package/docs/highlight/styles/atelier-savanna-dark.css +0 -84
  56. package/docs/highlight/styles/atelier-savanna-light.css +0 -84
  57. package/docs/highlight/styles/atelier-seaside-dark.css +0 -69
  58. package/docs/highlight/styles/atelier-seaside-light.css +0 -69
  59. package/docs/highlight/styles/atelier-sulphurpool-dark.css +0 -69
  60. package/docs/highlight/styles/atelier-sulphurpool-light.css +0 -69
  61. package/docs/highlight/styles/atom-one-dark-reasonable.css +0 -77
  62. package/docs/highlight/styles/atom-one-dark.css +0 -96
  63. package/docs/highlight/styles/atom-one-light.css +0 -96
  64. package/docs/highlight/styles/brown-paper.css +0 -64
  65. package/docs/highlight/styles/brown-papersq.png +0 -0
  66. package/docs/highlight/styles/codepen-embed.css +0 -60
  67. package/docs/highlight/styles/color-brewer.css +0 -71
  68. package/docs/highlight/styles/darcula.css +0 -77
  69. package/docs/highlight/styles/dark.css +0 -63
  70. package/docs/highlight/styles/darkula.css +0 -6
  71. package/docs/highlight/styles/default.css +0 -99
  72. package/docs/highlight/styles/docco.css +0 -97
  73. package/docs/highlight/styles/dracula.css +0 -76
  74. package/docs/highlight/styles/far.css +0 -71
  75. package/docs/highlight/styles/foundation.css +0 -88
  76. package/docs/highlight/styles/github-gist.css +0 -71
  77. package/docs/highlight/styles/github.css +0 -99
  78. package/docs/highlight/styles/gml.css +0 -78
  79. package/docs/highlight/styles/googlecode.css +0 -89
  80. package/docs/highlight/styles/grayscale.css +0 -101
  81. package/docs/highlight/styles/gruvbox-dark.css +0 -108
  82. package/docs/highlight/styles/gruvbox-light.css +0 -108
  83. package/docs/highlight/styles/hopscotch.css +0 -83
  84. package/docs/highlight/styles/hybrid.css +0 -102
  85. package/docs/highlight/styles/idea.css +0 -97
  86. package/docs/highlight/styles/ir-black.css +0 -73
  87. package/docs/highlight/styles/isbl-editor-dark.css +0 -112
  88. package/docs/highlight/styles/isbl-editor-light.css +0 -112
  89. package/docs/highlight/styles/kimbie.dark.css +0 -74
  90. package/docs/highlight/styles/kimbie.light.css +0 -74
  91. package/docs/highlight/styles/lightfair.css +0 -87
  92. package/docs/highlight/styles/magula.css +0 -70
  93. package/docs/highlight/styles/mono-blue.css +0 -59
  94. package/docs/highlight/styles/monokai-sublime.css +0 -83
  95. package/docs/highlight/styles/monokai.css +0 -70
  96. package/docs/highlight/styles/nord.css +0 -309
  97. package/docs/highlight/styles/obsidian.css +0 -88
  98. package/docs/highlight/styles/ocean.css +0 -74
  99. package/docs/highlight/styles/paraiso-dark.css +0 -72
  100. package/docs/highlight/styles/paraiso-light.css +0 -72
  101. package/docs/highlight/styles/pojoaque.css +0 -83
  102. package/docs/highlight/styles/pojoaque.jpg +0 -0
  103. package/docs/highlight/styles/purebasic.css +0 -96
  104. package/docs/highlight/styles/qtcreator_dark.css +0 -83
  105. package/docs/highlight/styles/qtcreator_light.css +0 -83
  106. package/docs/highlight/styles/railscasts.css +0 -106
  107. package/docs/highlight/styles/rainbow.css +0 -85
  108. package/docs/highlight/styles/routeros.css +0 -108
  109. package/docs/highlight/styles/school-book.css +0 -72
  110. package/docs/highlight/styles/school-book.png +0 -0
  111. package/docs/highlight/styles/shades-of-purple.css +0 -97
  112. package/docs/highlight/styles/solarized-dark.css +0 -84
  113. package/docs/highlight/styles/solarized-light.css +0 -84
  114. package/docs/highlight/styles/sunburst.css +0 -102
  115. package/docs/highlight/styles/tomorrow-night-blue.css +0 -75
  116. package/docs/highlight/styles/tomorrow-night-bright.css +0 -74
  117. package/docs/highlight/styles/tomorrow-night-eighties.css +0 -74
  118. package/docs/highlight/styles/tomorrow-night.css +0 -75
  119. package/docs/highlight/styles/tomorrow.css +0 -72
  120. package/docs/highlight/styles/vs.css +0 -68
  121. package/docs/highlight/styles/vs2015.css +0 -115
  122. package/docs/highlight/styles/xcode.css +0 -104
  123. package/docs/highlight/styles/xt256.css +0 -92
  124. package/docs/highlight/styles/zenburn.css +0 -80
  125. package/docs/images/console.svg +0 -12
  126. package/docs/images/dark_ss.png +0 -0
  127. package/docs/images/easy.svg +0 -14
  128. package/docs/images/fast.svg +0 -8
  129. package/docs/images/gears.svg +0 -11
  130. package/docs/images/light_ss.png +0 -0
  131. package/docs/images/logo-outline.png +0 -0
  132. package/docs/images/logo.png +0 -0
  133. package/docs/images/love.svg +0 -8
  134. package/docs/images/mask.svg +0 -16
  135. package/docs/images/mouse.svg +0 -7
  136. package/docs/images/pdf_sample1.png +0 -0
  137. package/docs/images/pdf_sample2.png +0 -0
  138. package/docs/images/webcomponent.svg +0 -13
  139. package/docs/index.css +0 -257
  140. package/docs/index.html +0 -186
  141. package/docs/rapipdf-min.js +0 -95
  142. package/docs/specs/allof-primitives.json +0 -80
  143. package/docs/specs/allof.json +0 -73
  144. package/docs/specs/anyof.json +0 -84
  145. package/docs/specs/basic.json +0 -75
  146. package/docs/specs/bitbucket.json +0 -12916
  147. package/docs/specs/data-types.yaml +0 -168
  148. package/docs/specs/gcloud.json +0 -1347
  149. package/docs/specs/no-server.json +0 -1
  150. package/docs/specs/oneof.json +0 -64
  151. package/docs/specs/petstore.json +0 -1042
  152. package/docs/specs/petstore_extended.yaml +0 -889
  153. package/docs/specs/temp.json +0 -53
  154. package/docs/specs/test-specs/large-models.json +0 -5998
  155. package/docs/specs/test-specs/long-descriptions.json +0 -5443
  156. package/docs/specs/test-specs/long-paths.json +0 -9562
  157. package/docs/specs/test-specs/oneof-allof-nested.yaml +0 -105
  158. package/docs/specs/test-specs/partial-spec-main.json +0 -29
  159. package/docs/specs/test-specs/partial.json +0 -17
  160. package/docs/specs/test-specs/petstore_complex_request.yaml +0 -335
  161. package/docs/specs/test-specs/petstore_experimental.yaml +0 -167
  162. package/docs/specs/test-specs/xxx-of-with-primitives-and-recursive-model.yaml +0 -952
  163. package/docs/welcome.html +0 -186
  164. package/index.html +0 -48
  165. package/logo.png +0 -0
  166. package/src/index.js +0 -3
  167. package/src/markdown.js +0 -120
  168. package/src/object-tree-gen.js +0 -370
  169. package/src/pdf-gen.js +0 -113
  170. package/src/pdf-parts-gen.js +0 -488
  171. package/src/rapipdf.js +0 -246
  172. package/src/spec-parser.js +0 -178
  173. package/src/table-layouts.js +0 -35
  174. package/src/vfs_fonts.js +0 -7
  175. package/webpack.config.js +0 -118
@@ -1,952 +0,0 @@
1
- openapi: 3.0.0
2
- servers:
3
- - url: //petstore.swagger.io/v2
4
- description: Default server
5
- - url: //petstore.swagger.io/sandbox
6
- description: Sandbox server
7
- info:
8
- description: |
9
- This is a sample server Petstore server.
10
- You can find out more about Swagger at
11
- [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/).
12
- For this sample, you can use the api key `special-key` to test the authorization filters.
13
-
14
- # Introduction
15
- This API is documented in **OpenAPI format** and is based on
16
- [Petstore sample](http://petstore.swagger.io/) provided by [swagger.io](http://swagger.io) team.
17
- It was **extended** to illustrate features of [generator-openapi-repo](https://github.com/Rebilly/generator-openapi-repo)
18
- tool and [ReDoc](https://github.com/Redocly/redoc) documentation. In addition to standard
19
- OpenAPI syntax we use a few [vendor extensions](https://github.com/Redocly/redoc/blob/master/docs/redoc-vendor-extensions.md).
20
-
21
- # OpenAPI Specification
22
- This API is documented in **OpenAPI format** and is based on
23
- [Petstore sample](http://petstore.swagger.io/) provided by [swagger.io](http://swagger.io) team.
24
- It was **extended** to illustrate features of [generator-openapi-repo](https://github.com/Rebilly/generator-openapi-repo)
25
- tool and [ReDoc](https://github.com/Redocly/redoc) documentation. In addition to standard
26
- OpenAPI syntax we use a few [vendor extensions](https://github.com/Redocly/redoc/blob/master/docs/redoc-vendor-extensions.md).
27
-
28
- # Cross-Origin Resource Sharing
29
- This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/).
30
- And that allows cross-domain communication from the browser.
31
- All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
32
-
33
- # Authentication
34
-
35
- Petstore offers two forms of authentication:
36
- - API Key
37
- - OAuth2
38
- OAuth2 - an open protocol to allow secure authorization in a simple
39
- and standard method from web, mobile and desktop applications.
40
-
41
- <SecurityDefinitions />
42
-
43
- version: 1.0.0
44
- title: Swagger Petstore
45
- termsOfService: 'http://swagger.io/terms/'
46
- contact:
47
- name: API Support
48
- email: apiteam@swagger.io
49
- url: https://github.com/Redocly/redoc
50
- x-logo:
51
- url: 'https://redocly.github.io/redoc/petstore-logo.png'
52
- altText: Petstore logo
53
- license:
54
- name: Apache 2.0
55
- url: 'http://www.apache.org/licenses/LICENSE-2.0.html'
56
- externalDocs:
57
- description: Find out how to create Github repo for your OpenAPI spec.
58
- url: 'https://github.com/Rebilly/generator-openapi-repo'
59
- tags:
60
- - name: pet
61
- description: Everything about your Pets
62
- - name: store
63
- description: Access to Petstore orders
64
- - name: user
65
- description: Operations about user
66
- - name: pet_model
67
- x-displayName: The Pet Model
68
- description: |
69
- <SchemaDefinition schemaRef="#/components/schemas/Pet" />
70
- - name: store_model
71
- x-displayName: The Order Model
72
- description: |
73
- <SchemaDefinition schemaRef="#/components/schemas/Order" exampleRef="#/components/examples/Order" showReadOnly={true} showWriteOnly={true} />
74
- x-tagGroups:
75
- - name: General
76
- tags:
77
- - pet
78
- - store
79
- - name: User Management
80
- tags:
81
- - user
82
- - name: Models
83
- tags:
84
- - pet_model
85
- - store_model
86
- paths:
87
- /pet:
88
- parameters:
89
- - name: cookieParam
90
- in: cookie
91
- description: Some cookie
92
- required: true
93
- schema:
94
- type: integer
95
- format: int64
96
- post:
97
- tags:
98
- - pet
99
- summary: Add a new pet to the store
100
- description: Add new pet to the store inventory.
101
- operationId: addPet
102
- responses:
103
- '405':
104
- description: Invalid input
105
- security:
106
- - petstore_auth:
107
- - 'write:pets'
108
- - 'read:pets'
109
- x-code-samples:
110
- - lang: 'C#'
111
- source: |
112
- PetStore.v1.Pet pet = new PetStore.v1.Pet();
113
- pet.setApiKey("your api key");
114
- pet.petType = PetStore.v1.Pet.TYPE_DOG;
115
- pet.name = "Rex";
116
- // set other fields
117
- PetStoreResponse response = pet.create();
118
- if (response.statusCode == HttpStatusCode.Created)
119
- {
120
- // Successfully created
121
- }
122
- else
123
- {
124
- // Something wrong -- check response for errors
125
- Console.WriteLine(response.getRawResponse());
126
- }
127
- - lang: PHP
128
- source: |
129
- $form = new \PetStore\Entities\Pet();
130
- $form->setPetType("Dog");
131
- $form->setName("Rex");
132
- // set other fields
133
- try {
134
- $pet = $client->pets()->create($form);
135
- } catch (UnprocessableEntityException $e) {
136
- var_dump($e->getErrors());
137
- }
138
- requestBody:
139
- $ref: '#/components/requestBodies/Pet'
140
- put:
141
- tags:
142
- - pet
143
- summary: Update an existing pet
144
- description: ''
145
- operationId: updatePet
146
- responses:
147
- '400':
148
- description: Invalid ID supplied
149
- '404':
150
- description: Pet not found
151
- '405':
152
- description: Validation exception
153
- security:
154
- - petstore_auth:
155
- - 'write:pets'
156
- - 'read:pets'
157
- x-code-samples:
158
- - lang: PHP
159
- source: |
160
- $form = new \PetStore\Entities\Pet();
161
- $form->setPetId(1);
162
- $form->setPetType("Dog");
163
- $form->setName("Rex");
164
- // set other fields
165
- try {
166
- $pet = $client->pets()->update($form);
167
- } catch (UnprocessableEntityException $e) {
168
- var_dump($e->getErrors());
169
- }
170
- requestBody:
171
- $ref: '#/components/requestBodies/Pet'
172
- '/pet/{petId}':
173
- get:
174
- tags:
175
- - pet
176
- summary: Find pet by ID
177
- description: Returns a single pet
178
- operationId: getPetById
179
- parameters:
180
- - name: petId
181
- in: path
182
- description: ID of pet to return
183
- required: true
184
- deprecated: true
185
- schema:
186
- type: integer
187
- format: int64
188
- responses:
189
- '200':
190
- description: successful operation
191
- content:
192
- application/json:
193
- schema:
194
- $ref: '#/components/schemas/Pet'
195
- application/xml:
196
- schema:
197
- $ref: '#/components/schemas/Pet'
198
- '400':
199
- description: Invalid ID supplied
200
- '404':
201
- description: Pet not found
202
- security:
203
- - api_key: []
204
- post:
205
- tags:
206
- - pet
207
- summary: Updates a pet in the store with form data
208
- description: ''
209
- operationId: updatePetWithForm
210
- parameters:
211
- - name: petId
212
- in: path
213
- description: ID of pet that needs to be updated
214
- required: true
215
- schema:
216
- type: integer
217
- format: int64
218
- responses:
219
- '405':
220
- description: Invalid input
221
- security:
222
- - petstore_auth:
223
- - 'write:pets'
224
- - 'read:pets'
225
- requestBody:
226
- content:
227
- application/x-www-form-urlencoded:
228
- schema:
229
- type: object
230
- properties:
231
- name:
232
- description: Updated name of the pet
233
- type: string
234
- status:
235
- description: Updated status of the pet
236
- type: string
237
- delete:
238
- tags:
239
- - pet
240
- summary: Deletes a pet
241
- description: ''
242
- operationId: deletePet
243
- parameters:
244
- - name: api_key
245
- in: header
246
- required: false
247
- schema:
248
- type: string
249
- example: "Bearer <TOKEN>"
250
- - name: petId
251
- in: path
252
- description: Pet id to delete
253
- required: true
254
- schema:
255
- type: integer
256
- format: int64
257
- responses:
258
- '400':
259
- description: Invalid pet value
260
- security:
261
- - petstore_auth:
262
- - 'write:pets'
263
- - 'read:pets'
264
- '/pet/{petId}/uploadImage':
265
- post:
266
- tags:
267
- - pet
268
- summary: uploads an image
269
- description: ''
270
- operationId: uploadFile
271
- parameters:
272
- - name: petId
273
- in: path
274
- description: ID of pet to update
275
- required: true
276
- schema:
277
- type: integer
278
- format: int64
279
- responses:
280
- '200':
281
- description: successful operation
282
- content:
283
- application/json:
284
- schema:
285
- $ref: '#/components/schemas/ApiResponse'
286
- security:
287
- - petstore_auth:
288
- - 'write:pets'
289
- - 'read:pets'
290
- requestBody:
291
- content:
292
- application/octet-stream:
293
- schema:
294
- type: string
295
- format: binary
296
- /pet/findByStatus:
297
- get:
298
- tags:
299
- - pet
300
- summary: Finds Pets by status
301
- description: Multiple status values can be provided with comma seperated strings
302
- operationId: findPetsByStatus
303
- parameters:
304
- - name: status
305
- in: query
306
- description: Status values that need to be considered for filter
307
- required: true
308
- style: form
309
- schema:
310
- type: array
311
- minItems: 1
312
- maxItems: 3
313
- items:
314
- type: string
315
- enum:
316
- - available
317
- - pending
318
- - sold
319
- default: available
320
- responses:
321
- '200':
322
- description: successful operation
323
- content:
324
- application/json:
325
- schema:
326
- type: array
327
- items:
328
- $ref: '#/components/schemas/Pet'
329
- application/xml:
330
- schema:
331
- type: array
332
- items:
333
- $ref: '#/components/schemas/Pet'
334
- '400':
335
- description: Invalid status value
336
- security:
337
- - petstore_auth:
338
- - 'write:pets'
339
- - 'read:pets'
340
- /pet/findByTags:
341
- get:
342
- tags:
343
- - pet
344
- summary: Finds Pets by tags
345
- description: >-
346
- Muliple tags can be provided with comma seperated strings. Use tag1,
347
- tag2, tag3 for testing.
348
- operationId: findPetsByTags
349
- deprecated: true
350
- parameters:
351
- - name: tags
352
- in: query
353
- description: Tags to filter by
354
- required: true
355
- style: form
356
- schema:
357
- type: array
358
- items:
359
- type: string
360
- responses:
361
- '200':
362
- description: successful operation
363
- content:
364
- application/json:
365
- schema:
366
- type: array
367
- items:
368
- $ref: '#/components/schemas/Pet'
369
- application/xml:
370
- schema:
371
- type: array
372
- items:
373
- $ref: '#/components/schemas/Pet'
374
- '400':
375
- description: Invalid tag value
376
- security:
377
- - petstore_auth:
378
- - 'write:pets'
379
- - 'read:pets'
380
- /store/inventory:
381
- get:
382
- tags:
383
- - store
384
- summary: Returns pet inventories by status
385
- description: Returns a map of status codes to quantities
386
- operationId: getInventory
387
- responses:
388
- '200':
389
- description: successful operation
390
- content:
391
- application/json:
392
- schema:
393
- type: object
394
- additionalProperties:
395
- type: integer
396
- format: int32
397
- security:
398
- - api_key: []
399
- /store/order:
400
- post:
401
- tags:
402
- - store
403
- summary: Place an order for a pet
404
- description: ''
405
- operationId: placeOrder
406
- responses:
407
- '200':
408
- description: successful operation
409
- content:
410
- application/json:
411
- schema:
412
- $ref: '#/components/schemas/Order'
413
- application/xml:
414
- schema:
415
- $ref: '#/components/schemas/Order'
416
- '400':
417
- description: Invalid Order
418
- content:
419
- application/json:
420
- example:
421
- status: 400
422
- message: "Invalid Order"
423
- requestBody:
424
- content:
425
- application/json:
426
- schema:
427
- $ref: '#/components/schemas/Order'
428
- description: order placed for purchasing the pet
429
- required: true
430
- '/store/order/{orderId}':
431
- get:
432
- tags:
433
- - store
434
- summary: Find purchase order by ID
435
- description: >-
436
- For valid response try integer IDs with value <= 5 or > 10. Other values
437
- will generated exceptions
438
- operationId: getOrderById
439
- parameters:
440
- - name: orderId
441
- in: path
442
- description: ID of pet that needs to be fetched
443
- required: true
444
- schema:
445
- type: integer
446
- format: int64
447
- minimum: 1
448
- maximum: 5
449
- responses:
450
- '200':
451
- description: successful operation
452
- content:
453
- application/json:
454
- schema:
455
- $ref: '#/components/schemas/Order'
456
- application/xml:
457
- schema:
458
- $ref: '#/components/schemas/Order'
459
- '400':
460
- description: Invalid ID supplied
461
- '404':
462
- description: Order not found
463
- delete:
464
- tags:
465
- - store
466
- summary: Delete purchase order by ID
467
- description: >-
468
- For valid response try integer IDs with value < 1000. Anything above
469
- 1000 or nonintegers will generate API errors
470
- operationId: deleteOrder
471
- parameters:
472
- - name: orderId
473
- in: path
474
- description: ID of the order that needs to be deleted
475
- required: true
476
- schema:
477
- type: string
478
- minimum: 1
479
- responses:
480
- '400':
481
- description: Invalid ID supplied
482
- '404':
483
- description: Order not found
484
- /user:
485
- post:
486
- tags:
487
- - user
488
- summary: Create user
489
- description: This can only be done by the logged in user.
490
- operationId: createUser
491
- responses:
492
- default:
493
- description: successful operation
494
- requestBody:
495
- content:
496
- application/json:
497
- schema:
498
- $ref: '#/components/schemas/User'
499
- description: Created user object
500
- required: true
501
- '/user/{username}':
502
- get:
503
- tags:
504
- - user
505
- summary: Get user by user name
506
- description: ''
507
- operationId: getUserByName
508
- parameters:
509
- - name: username
510
- in: path
511
- description: 'The name that needs to be fetched. Use user1 for testing. '
512
- required: true
513
- schema:
514
- type: string
515
- responses:
516
- '200':
517
- description: successful operation
518
- content:
519
- application/json:
520
- schema:
521
- $ref: '#/components/schemas/User'
522
- application/xml:
523
- schema:
524
- $ref: '#/components/schemas/User'
525
- '400':
526
- description: Invalid username supplied
527
- '404':
528
- description: User not found
529
- put:
530
- tags:
531
- - user
532
- summary: Updated user
533
- description: This can only be done by the logged in user.
534
- operationId: updateUser
535
- parameters:
536
- - name: username
537
- in: path
538
- description: name that need to be deleted
539
- required: true
540
- schema:
541
- type: string
542
- responses:
543
- '400':
544
- description: Invalid user supplied
545
- '404':
546
- description: User not found
547
- requestBody:
548
- content:
549
- application/json:
550
- schema:
551
- $ref: '#/components/schemas/User'
552
- description: Updated user object
553
- required: true
554
- delete:
555
- tags:
556
- - user
557
- summary: Delete user
558
- description: This can only be done by the logged in user.
559
- operationId: deleteUser
560
- parameters:
561
- - name: username
562
- in: path
563
- description: The name that needs to be deleted
564
- required: true
565
- schema:
566
- type: string
567
- responses:
568
- '400':
569
- description: Invalid username supplied
570
- '404':
571
- description: User not found
572
- /user/createWithArray:
573
- post:
574
- tags:
575
- - user
576
- summary: Creates list of users with given input array
577
- description: ''
578
- operationId: createUsersWithArrayInput
579
- responses:
580
- default:
581
- description: successful operation
582
- requestBody:
583
- $ref: '#/components/requestBodies/UserArray'
584
- /user/createWithList:
585
- post:
586
- tags:
587
- - user
588
- summary: Creates list of users with given input array
589
- description: ''
590
- operationId: createUsersWithListInput
591
- responses:
592
- default:
593
- description: successful operation
594
- requestBody:
595
- $ref: '#/components/requestBodies/UserArray'
596
- /user/login:
597
- get:
598
- tags:
599
- - user
600
- summary: Logs user into the system
601
- description: ''
602
- operationId: loginUser
603
- parameters:
604
- - name: username
605
- in: query
606
- description: The user name for login
607
- required: true
608
- schema:
609
- type: string
610
- - name: password
611
- in: query
612
- description: The password for login in clear text
613
- required: true
614
- schema:
615
- type: string
616
- responses:
617
- '200':
618
- description: successful operation
619
- headers:
620
- X-Rate-Limit:
621
- description: calls per hour allowed by the user
622
- schema:
623
- type: integer
624
- format: int32
625
- X-Expires-After:
626
- description: date in UTC when toekn expires
627
- schema:
628
- type: string
629
- format: date-time
630
- content:
631
- application/json:
632
- schema:
633
- type: string
634
- examples:
635
- response:
636
- value: OK
637
- application/xml:
638
- schema:
639
- type: string
640
- examples:
641
- response:
642
- value: <Message> OK </Message>
643
- text/plain:
644
- examples:
645
- response:
646
- value: OK
647
- '400':
648
- description: Invalid username/password supplied
649
- /user/logout:
650
- get:
651
- tags:
652
- - user
653
- summary: Logs out current logged in user session
654
- description: ''
655
- operationId: logoutUser
656
- responses:
657
- default:
658
- description: successful operation
659
- components:
660
- schemas:
661
- ApiResponse:
662
- type: object
663
- properties:
664
- code:
665
- type: integer
666
- format: int32
667
- type:
668
- type: string
669
- message:
670
- type: string
671
- Cat:
672
- description: A representation of a cat
673
- allOf:
674
- - $ref: '#/components/schemas/Pet'
675
- - type: object
676
- properties:
677
- huntingSkill:
678
- type: string
679
- description: The measured skill for hunting
680
- default: lazy
681
- enum:
682
- - clueless
683
- - lazy
684
- - adventurous
685
- - aggressive
686
- required:
687
- - huntingSkill
688
- Category:
689
- type: object
690
- properties:
691
- id:
692
- description: Category ID
693
- allOf:
694
- - $ref: '#/components/schemas/Id'
695
- name:
696
- description: Category name
697
- type: string
698
- minLength: 1
699
- sub:
700
- description: Test Sub Category
701
- type: object
702
- properties:
703
- prop1:
704
- type: string
705
- description: Dumb Property
706
- xml:
707
- name: Category
708
- Dog:
709
- description: A representation of a dog
710
- allOf:
711
- - $ref: '#/components/schemas/Pet'
712
- - type: object
713
- properties:
714
- packSize:
715
- type: integer
716
- format: int32
717
- description: The size of the pack the dog is from
718
- default: 1
719
- minimum: 1
720
- required:
721
- - packSize
722
- HoneyBee:
723
- description: A representation of a honey bee
724
- allOf:
725
- - $ref: '#/components/schemas/Pet'
726
- - type: object
727
- properties:
728
- honeyPerDay:
729
- type: number
730
- description: Average amount of honey produced per day in ounces
731
- example: 3.14
732
- required:
733
- - honeyPerDay
734
- Id:
735
- type: integer
736
- format: int64
737
- readOnly: true
738
- Order:
739
- type: object
740
- properties:
741
- id:
742
- description: Order ID
743
- allOf:
744
- - $ref: '#/components/schemas/Id'
745
- petId:
746
- description: Pet ID
747
- allOf:
748
- - $ref: '#/components/schemas/Id'
749
- quantity:
750
- type: integer
751
- format: int32
752
- minimum: 1
753
- default: 1
754
- shipDate:
755
- description: Estimated ship date
756
- type: string
757
- format: date-time
758
- status:
759
- type: string
760
- description: Order Status
761
- enum:
762
- - placed
763
- - approved
764
- - delivered
765
- complete:
766
- description: Indicates whenever order was completed or not
767
- type: boolean
768
- default: false
769
- readOnly: true
770
- rqeuestId:
771
- description: Unique Request Id
772
- type: string
773
- writeOnly: true
774
- xml:
775
- name: Order
776
- Pet:
777
- type: object
778
- required:
779
- - name
780
- - photoUrls
781
- discriminator:
782
- propertyName: petType
783
- mapping:
784
- cat: '#/components/schemas/Cat'
785
- dog: '#/components/schemas/Dog'
786
- bee: '#/components/schemas/HoneyBee'
787
- properties:
788
- id:
789
- externalDocs:
790
- description: "Find more info here"
791
- url: "https://example.com"
792
- description: Pet ID
793
- allOf:
794
- - $ref: '#/components/schemas/Id'
795
- category:
796
- description: Categories this pet belongs to
797
- allOf:
798
- - $ref: '#/components/schemas/Category'
799
- name:
800
- description: The name given to a pet
801
- type: string
802
- example: Guru
803
- photoUrls:
804
- description: The list of URL to a cute photos featuring pet
805
- type: array
806
- maxItems: 20
807
- xml:
808
- name: photoUrl
809
- wrapped: true
810
- items:
811
- type: string
812
- format: url
813
- friend:
814
- allOf:
815
- - $ref: '#/components/schemas/Pet'
816
- tags:
817
- description: Tags attached to the pet
818
- type: array
819
- minItems: 1
820
- xml:
821
- name: tag
822
- wrapped: true
823
- items:
824
- $ref: '#/components/schemas/Tag'
825
- status:
826
- type: string
827
- description: Pet status in the store
828
- enum:
829
- - available
830
- - pending
831
- - sold
832
- petType:
833
- description: Type of a pet
834
- type: string
835
- xml:
836
- name: Pet
837
- Tag:
838
- type: object
839
- properties:
840
- id:
841
- description: Tag ID
842
- allOf:
843
- - $ref: '#/components/schemas/Id'
844
- name:
845
- description: Tag name
846
- type: string
847
- minLength: 1
848
- xml:
849
- name: Tag
850
- User:
851
- type: object
852
- properties:
853
- id:
854
- $ref: '#/components/schemas/Id'
855
- pet:
856
- oneOf:
857
- - $ref: '#/components/schemas/Pet'
858
- - $ref: '#/components/schemas/Tag'
859
- username:
860
- description: User supplied username
861
- type: string
862
- minLength: 4
863
- example: John78
864
- firstName:
865
- description: User first name
866
- type: string
867
- minLength: 1
868
- example: John
869
- lastName:
870
- description: User last name
871
- type: string
872
- minLength: 1
873
- example: Smith
874
- email:
875
- description: User email address
876
- type: string
877
- format: email
878
- example: john.smith@example.com
879
- password:
880
- type: string
881
- description: >-
882
- User password, MUST contain a mix of upper and lower case letters,
883
- as well as digits
884
- format: password
885
- minLength: 8
886
- pattern: '/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])/'
887
- example: drowssaP123
888
- phone:
889
- description: User phone number in international format
890
- type: string
891
- pattern: '/^\+(?:[0-9]-?){6,14}[0-9]$/'
892
- example: +1-202-555-0192
893
- nullable: true
894
- userStatus:
895
- description: User status
896
- type: integer
897
- format: int32
898
- xml:
899
- name: User
900
- requestBodies:
901
- Pet:
902
- content:
903
- application/json:
904
- schema:
905
- allOf:
906
- - description: My Pet
907
- title: Pettie
908
- - $ref: '#/components/schemas/Pet'
909
- application/xml:
910
- schema:
911
- type: 'object'
912
- properties:
913
- name:
914
- type: string
915
- description: hooray
916
- description: Pet object that needs to be added to the store
917
- required: true
918
- UserArray:
919
- content:
920
- application/json:
921
- schema:
922
- type: array
923
- items:
924
- $ref: '#/components/schemas/User'
925
- description: List of user object
926
- required: true
927
- securitySchemes:
928
- petstore_auth:
929
- description: |
930
- Get access to data while protecting your account credentials.
931
- OAuth2 is also a safer and more secure way to give you access.
932
- type: oauth2
933
- flows:
934
- implicit:
935
- authorizationUrl: 'http://petstore.swagger.io/api/oauth/dialog'
936
- scopes:
937
- 'write:pets': modify pets in your account
938
- 'read:pets': read your pets
939
- api_key:
940
- description: >
941
- For this sample, you can use the api key `special-key` to test the
942
- authorization filters.
943
- type: apiKey
944
- name: api_key
945
- in: header
946
- examples:
947
- Order:
948
- value:
949
- quantity: 1,
950
- shipDate: 2018-10-19T16:46:45Z,
951
- status: placed,
952
- complete: false