Missing licence info added in pom file
[cps.git] / cps-rest / docs / openapi / components.yml
1 # ============LICENSE_START=======================================================
2 # Copyright (c) 2021 Bell Canada.
3 # ================================================================================
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #       http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 # ============LICENSE_END=========================================================
16
17 components:
18   schemas:
19     ErrorMessage:
20       type: object
21       title: Error
22       properties:
23         status:
24           type: string
25           example: 400
26         message:
27           type: string
28           example: Dataspace not found
29         details:
30           type: string
31           example: Dataspace with name D1 does not exist.
32
33     MultipartFile:
34       required:
35         - file
36       properties:
37         multipartFile:
38           type: string
39           description: multipartFile
40           format: binary
41           example: http://example.com/examples/example.yang
42
43   parameters:
44     dataspaceNameInQuery:
45       name: dataspace-name
46       in: query
47       description: dataspace-name
48       required: true
49       schema:
50         type: string
51     dataspaceNameInPath:
52       name: dataspace-name
53       in: path
54       description: dataspace-name
55       required: true
56       schema:
57         type: string
58     anchorNameInPath:
59       name: anchor-name
60       in: path
61       description: anchor-name
62       required: true
63       schema:
64         type: string
65     schemaSetNameInQuery:
66       name: schema-set-name
67       in: query
68       description: schema-set-name
69       required: true
70       schema:
71         type: string
72     schemaSetNameInPath:
73       name: schema-set-name
74       in: path
75       description: schema-set-name
76       required: true
77       schema:
78         type: string
79     anchorNameInQuery:
80       name: anchor-name
81       in: query
82       description: anchor-name
83       required: true
84       schema:
85         type: string
86     xpathInQuery:
87       name: xpath
88       in: query
89       description: xpath
90       required: false
91       schema:
92         type: string
93         default: /
94     requiredXpathInQuery:
95       name: xpath
96       in: query
97       description: xpath
98       required: true
99       schema:
100         type: string
101     cpsPathInQuery:
102       name: cps-path
103       in: query
104       description: cps-path
105       required: false
106       schema:
107         type: string
108         default: /
109     includeDescendantsOptionInQuery:
110       name: include-descendants
111       in: query
112       description: include-descendants
113       required: false
114       schema:
115         type: boolean
116         default: false
117
118   responses:
119     NotFound:
120       description: The specified resource was not found
121       content:
122         application/json:
123           schema:
124             $ref: '#/components/schemas/ErrorMessage'
125     Unauthorized:
126       description: Unauthorized
127       content:
128         application/json:
129           schema:
130             $ref: '#/components/schemas/ErrorMessage'
131     Forbidden:
132       description: Forbidden
133       content:
134         application/json:
135           schema:
136             $ref: '#/components/schemas/ErrorMessage'
137     BadRequest:
138       description: Bad Request
139       content:
140         application/json:
141           schema:
142             $ref: '#/components/schemas/ErrorMessage'
143     Conflict:
144       description: Conflict
145       content:
146         application/json:
147           schema:
148             $ref: '#/components/schemas/ErrorMessage'
149     Ok:
150       description: OK
151       content:
152         application/json:
153           schema:
154             type: object
155     Created:
156       description: Created
157       content:
158         text/plain:
159           schema:
160             type: string
161     NoContent:
162       description: No Content
163       content: {}