blob: cb5594868654783a35dcdab08a4a3a3313bc22dc [file] [log] [blame]
shivasubedi8df61a92021-06-16 14:43:18 +01001# ============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
Rishi.Chaildacc6632021-01-27 04:27:34 +000017dataspaces:
puthuparambil.aditya001e7732021-01-13 12:06:20 +000018 post:
Rishi.Chail6d13f162021-01-26 05:58:39 +000019 description: Create a new dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +000020 tags:
21 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +000022 summary: Create a dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +000023 operationId: createDataspace
24 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +000025 - $ref: 'components.yml#/components/parameters/dataspaceNameInQuery'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000026 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +000027 '201':
28 $ref: 'components.yml#/components/responses/Created'
29 '400':
30 $ref: 'components.yml#/components/responses/BadRequest'
31 '401':
32 $ref: 'components.yml#/components/responses/Unauthorized'
33 '403':
34 $ref: 'components.yml#/components/responses/Forbidden'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000035
36dataspaceByDataspaceName:
37 delete:
Rishi.Chail6d13f162021-01-26 05:58:39 +000038 description: Delete the given dataspace - DRAFT
puthuparambil.aditya001e7732021-01-13 12:06:20 +000039 tags:
40 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +000041 summary: Delete a dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +000042 operationId: deleteDataspace
43 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +000044 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000045 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +000046 '200':
47 $ref: 'components.yml#/components/responses/Ok'
48 '204':
49 $ref: 'components.yml#/components/responses/NoContent'
50 '400':
51 $ref: 'components.yml#/components/responses/BadRequest'
52 '401':
53 $ref: 'components.yml#/components/responses/Unauthorized'
54 '403':
55 $ref: 'components.yml#/components/responses/Forbidden'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000056
57
58schemaSet:
59 post:
Rishi.Chail6d13f162021-01-26 05:58:39 +000060 description: Create a new schema set in the given dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +000061 tags:
62 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +000063 summary: Create a schema set
puthuparambil.aditya001e7732021-01-13 12:06:20 +000064 operationId: createSchemaSet
65 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +000066 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
67 - $ref: 'components.yml#/components/parameters/schemaSetNameInQuery'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000068 requestBody:
69 required: true
70 content:
71 multipart/form-data:
72 schema:
Rishi.Chail6d13f162021-01-26 05:58:39 +000073 $ref: 'components.yml#/components/schemas/MultipartFile'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000074
75 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +000076 '201':
77 $ref: 'components.yml#/components/responses/Created'
78 '400':
79 $ref: 'components.yml#/components/responses/BadRequest'
80 '401':
81 $ref: 'components.yml#/components/responses/Unauthorized'
82 '403':
83 $ref: 'components.yml#/components/responses/Forbidden'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000084
85schemaSetBySchemaSetName:
86 get:
Rishi.Chail6d13f162021-01-26 05:58:39 +000087 description: Read a schema set given a schema set name and a dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +000088 tags:
89 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +000090 summary: Get a schema set
puthuparambil.aditya001e7732021-01-13 12:06:20 +000091 operationId: getSchemaSet
92 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +000093 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
94 - $ref: 'components.yml#/components/parameters/schemaSetNameInPath'
puthuparambil.aditya001e7732021-01-13 12:06:20 +000095 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +000096 '200':
97 $ref: 'components.yml#/components/responses/Ok'
98 '400':
99 $ref: 'components.yml#/components/responses/BadRequest'
100 '401':
101 $ref: 'components.yml#/components/responses/Unauthorized'
102 '403':
103 $ref: 'components.yml#/components/responses/Forbidden'
104 '404':
105 $ref: 'components.yml#/components/responses/NotFound'
106
Ruslan Kashapovdce4e312021-01-11 15:34:10 +0200107 delete:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000108 description: Delete a schema set given a schema set name and a dataspace
Ruslan Kashapovdce4e312021-01-11 15:34:10 +0200109 tags:
110 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +0000111 summary: Delete a schema set
Ruslan Kashapovdce4e312021-01-11 15:34:10 +0200112 operationId: deleteSchemaSet
113 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000114 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
115 - $ref: 'components.yml#/components/parameters/schemaSetNameInPath'
Ruslan Kashapovdce4e312021-01-11 15:34:10 +0200116 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000117 '204':
118 $ref: 'components.yml#/components/responses/NoContent'
119 '400':
120 $ref: 'components.yml#/components/responses/BadRequest'
121 '401':
122 $ref: 'components.yml#/components/responses/Unauthorized'
123 '403':
124 $ref: 'components.yml#/components/responses/Forbidden'
125 '409':
126 $ref: 'components.yml#/components/responses/Conflict'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000127
128anchorsByDataspace:
129 get:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000130 description: Read all anchors, given a dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000131 tags:
132 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +0000133 summary: Get anchors
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000134 operationId: getAnchors
135 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000136 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000137 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000138 '200':
139 $ref: 'components.yml#/components/responses/Ok'
140 '400':
141 $ref: 'components.yml#/components/responses/BadRequest'
142 '401':
143 $ref: 'components.yml#/components/responses/Unauthorized'
144 '403':
145 $ref: 'components.yml#/components/responses/Forbidden'
146 '404':
147 $ref: 'components.yml#/components/responses/NotFound'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000148
149 post:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000150 description: Create a new anchor in the given dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000151 tags:
152 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +0000153 summary: Create an anchor
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000154 operationId: createAnchor
155 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000156 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
157 - $ref: 'components.yml#/components/parameters/schemaSetNameInQuery'
158 - $ref: 'components.yml#/components/parameters/anchorNameInQuery'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000159 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000160 '201':
161 $ref: 'components.yml#/components/responses/Created'
162 '400':
163 $ref: 'components.yml#/components/responses/BadRequest'
164 '401':
165 $ref: 'components.yml#/components/responses/Unauthorized'
166 '403':
167 $ref: 'components.yml#/components/responses/Forbidden'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000168
169anchorByDataspaceAndAnchorName:
170 get:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000171 description: Read an anchor given an anchor name and a dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000172 tags:
173 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +0000174 summary: Get an anchor
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000175 operationId: getAnchor
176 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000177 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
178 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000179 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000180 '200':
181 $ref: 'components.yml#/components/responses/Ok'
182 '400':
183 $ref: 'components.yml#/components/responses/BadRequest'
184 '401':
185 $ref: 'components.yml#/components/responses/Unauthorized'
186 '403':
187 $ref: 'components.yml#/components/responses/Forbidden'
188 '404':
189 $ref: 'components.yml#/components/responses/NotFound'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000190
191 delete:
Ruslan Kashapovb20858b2021-04-05 14:46:03 +0300192 description: Delete an anchor given an anchor name and a dataspace
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000193 tags:
194 - cps-admin
Rishi.Chail6d13f162021-01-26 05:58:39 +0000195 summary: Delete an anchor
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000196 operationId: deleteAnchor
197 parameters:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000198 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
199 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
puthuparambil.aditya001e7732021-01-13 12:06:20 +0000200 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000201 '204':
202 $ref: 'components.yml#/components/responses/NoContent'
203 '400':
204 $ref: 'components.yml#/components/responses/BadRequest'
205 '401':
206 $ref: 'components.yml#/components/responses/Unauthorized'
207 '403':
208 $ref: 'components.yml#/components/responses/Forbidden'