...
1---
2swagger: "2.0"
3info:
4 version: "0.1.0"
5 title: reference analysis
6
7parameters:
8 idParam:
9 name: id
10 in: path
11 type: string
12 pattern: 'a[A-Za-Z0-9]+'
13
14responses:
15 notFound:
16 headers:
17 ContentLength:
18 type: string
19 pattern: '[0-9]+'
20 schema:
21 $ref: "#/definitions/error"
22
23paths:
24 "/some/where/{id}":
25 parameters:
26 - $ref: "#/parameters/idParam"
27 - name: name
28 in: query
29 pattern: 'b[A-Za-z0-9]+'
30 - name: bodyId
31 in: body
32 schema:
33 type: object
34 get:
35 parameters:
36 - name: filter
37 in: query
38 type: string
39 pattern: "[abc][0-9]+"
40 - name: other
41 in: query
42 type: array
43 items:
44 type: string
45 pattern: 'c[A-Za-z0-9]+'
46 - name: body
47 in: body
48 schema:
49 type: object
50
51 responses:
52 default:
53 schema:
54 type: object
55 404:
56 $ref: "#/responses/notFound"
57 200:
58 headers:
59 X-Request-Id:
60 type: string
61 pattern: 'd[A-Za-z0-9]+'
62 schema:
63 $ref: "#/definitions/tag"
64 "/other/place":
65 post:
66 parameters:
67 - name: body
68 in: body
69 schema:
70 type: object
71 properties:
72 value:
73 type: string
74 pattern: 'e[A-Za-z0-9]+'
75 responses:
76 default:
77 headers:
78 Via:
79 type: array
80 items:
81 type: string
82 pattern: '[A-Za-z]+'
83 200:
84 schema:
85 type: object
86 properties:
87 data:
88 type: string
89 pattern: "[0-9]+[abd]"
90
91definitions:
92 named:
93 type: string
94 pattern: 'f[A-Za-z0-9]+'
95 tag:
96 type: object
97 properties:
98 id:
99 type: integer
100 format: int64
101 value:
102 type: string
103 pattern: 'g[A-Za-z0-9]+'
104 audit:
105 $ref: "#/definitions/record"
106 record:
107 type: object
108 properties:
109 createdAt:
110 type: string
111 format: date-time
112 error:
113 type: object
114 required:
115 - id
116 - message
117 properties:
118 id:
119 type: integer
120 format: int64
121 readOnly: true
122 message:
123 type: string
124 readOnly: true
125 withPatternProperties:
126 type: object
127 additionalProperties: true
128 patternProperties:
129 '^prop[0-9]+$':
130 type: string
View as plain text