blob: 4418a3b9b70c105d5cf9c3d44ba651978a690e4f [file] [log] [blame]
shivasubedi8df61a92021-06-16 14:43:18 +01001# ============LICENSE_START=======================================================
puthuparambil.adityacc17ae52022-02-25 13:24:03 +00002# Copyright (c) 2021-2022 Bell Canada.
JosephKeenan909a8502022-01-28 10:02:24 +00003# Modifications Copyright (C) 2021-2022 Nordix Foundation
Rudrangi Anupriya1decb392024-06-05 23:55:14 +05304# Modifications Copyright (C) 2022-2024 TechMahindra Ltd.
Michal Jagiello6ce84d92022-12-13 07:40:19 +00005# Modifications Copyright (C) 2022 Deutsche Telekom AG
shivasubedi8df61a92021-06-16 14:43:18 +01006# ================================================================================
7# Licensed under the Apache License, Version 2.0 (the "License");
8# you may not use this file except in compliance with the License.
9# You may obtain a copy of the License at
10#
11# http://www.apache.org/licenses/LICENSE-2.0
12#
13# Unless required by applicable law or agreed to in writing, software
14# distributed under the License is distributed on an "AS IS" BASIS,
15# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16# See the License for the specific language governing permissions and
17# limitations under the License.
Renu Kumari4d520012021-08-30 11:50:43 -040018#
19# SPDX-License-Identifier: Apache-2.0
shivasubedi8df61a92021-06-16 14:43:18 +010020# ============LICENSE_END=========================================================
21
DylanB95ESTa79c9f12021-10-29 17:33:06 +010022listElementByDataspaceAndAnchor:
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030023 post:
DylanB95ESTa79c9f12021-10-29 17:33:06 +010024 description: Add list element(s) to a list for a given anchor and dataspace
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030025 tags:
26 - cps-data
DylanB95ESTa79c9f12021-10-29 17:33:06 +010027 summary: Add list element(s)
28 operationId: addListElements
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030029 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +000030 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030031 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
32 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
33 - $ref: 'components.yml#/components/parameters/requiredXpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +010034 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriyad0d4b972024-07-19 20:20:26 +053035 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030036 requestBody:
37 required: true
38 content:
39 application/json:
40 schema:
Rudrangi Anupriyad0d4b972024-07-19 20:20:26 +053041 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +000042 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +000043 dataSample:
44 $ref: 'components.yml#/components/examples/dataSample'
Rudrangi Anupriyad0d4b972024-07-19 20:20:26 +053045 application/xml:
46 schema:
47 type: object
48 xml:
49 name: stores
50 examples:
51 dataSample:
52 $ref: 'components.yml#/components/examples/dataSampleXml'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030053 responses:
54 '201':
55 $ref: 'components.yml#/components/responses/Created'
56 '400':
57 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030058 '403':
59 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +000060 '500':
61 $ref: 'components.yml#/components/responses/InternalServerError'
Renu Kumari7edbeb62021-08-30 07:45:52 -040062 put:
DylanB95ESTa79c9f12021-10-29 17:33:06 +010063 description: Replace list content under a given parent, anchor and dataspace
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030064 tags:
65 - cps-data
DylanB95ESTa79c9f12021-10-29 17:33:06 +010066 summary: Replace list content
67 operationId: replaceListContent
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030068 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +000069 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030070 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
71 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
72 - $ref: 'components.yml#/components/parameters/requiredXpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +010073 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030074 requestBody:
75 required: true
76 content:
77 application/json:
78 schema:
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +000079 type: object
80 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +000081 dataSample:
82 $ref: 'components.yml#/components/examples/dataSample'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030083 responses:
84 '200':
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +000085 $ref: 'components.yml#/components/responses/Ok'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030086 '400':
87 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030088 '403':
89 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +000090 '500':
91 $ref: 'components.yml#/components/responses/InternalServerError'
lukegleeson05701dd2021-08-18 09:49:32 +010092
Rishi.Chaildacc6632021-01-27 04:27:34 +000093nodesByDataspaceAndAnchor:
niamhcore74753d92021-01-28 16:11:52 +000094 post:
Rishi.Chail6d13f162021-01-26 05:58:39 +000095 description: Create a node for a given anchor and dataspace
niamhcore74753d92021-01-28 16:11:52 +000096 tags:
97 - cps-data
Rishi.Chail6d13f162021-01-26 05:58:39 +000098 summary: Create a node
niamhcore74753d92021-01-28 16:11:52 +000099 operationId: createNode
100 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000101 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Rishi.Chail6d13f162021-01-26 05:58:39 +0000102 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
103 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
Ruslan Kashapov24bf3502021-04-19 12:40:01 +0300104 - $ref: 'components.yml#/components/parameters/xpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +0100105 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530106 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
niamhcore74753d92021-01-28 16:11:52 +0000107 requestBody:
108 required: true
109 content:
110 application/json:
111 schema:
Michal Jagiello6ce84d92022-12-13 07:40:19 +0000112 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +0000113 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +0000114 dataSample:
115 $ref: 'components.yml#/components/examples/dataSample'
Michal Jagiello6ce84d92022-12-13 07:40:19 +0000116 application/xml:
117 schema:
118 type: object # Workaround to show example
119 xml:
120 name: stores
121 examples:
122 dataSample:
123 $ref: 'components.yml#/components/examples/dataSampleXml'
niamhcore74753d92021-01-28 16:11:52 +0000124 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000125 '201':
126 $ref: 'components.yml#/components/responses/Created'
127 '400':
128 $ref: 'components.yml#/components/responses/BadRequest'
Rishi.Chail6d13f162021-01-26 05:58:39 +0000129 '403':
130 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000131 '409':
132 $ref: 'components.yml#/components/responses/Conflict'
133 '500':
134 $ref: 'components.yml#/components/responses/InternalServerError'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200135 patch:
arpitsingh2b4c4882023-03-03 21:38:57 +0530136 description: Update a data node leaves for a given dataspace and anchor and a parent node xpath. This operation
137 is currently supported for one top level data node only.
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200138 tags:
139 - cps-data
140 summary: Update node leaves
141 operationId: updateNodeLeaves
142 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000143 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200144 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
145 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
146 - $ref: 'components.yml#/components/parameters/xpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +0100147 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530148 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200149 requestBody:
150 required: true
151 content:
152 application/json:
153 schema:
Rudrangi Anupriya1decb392024-06-05 23:55:14 +0530154 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +0000155 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +0000156 dataSample:
157 $ref: 'components.yml#/components/examples/dataSample'
Rudrangi Anupriya1decb392024-06-05 23:55:14 +0530158 application/xml:
159 schema:
160 type: object
161 xml:
162 name: stores
163 examples:
164 dataSample:
165 $ref: 'components.yml#/components/examples/dataSampleXml'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200166 responses:
167 '200':
168 $ref: 'components.yml#/components/responses/Ok'
169 '400':
170 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200171 '403':
172 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000173 '500':
174 $ref: 'components.yml#/components/responses/InternalServerError'
DylanB95EST30a59dd2021-11-02 17:25:18 +0000175 delete:
176 description: Delete a datanode for a given dataspace and anchor given a node xpath.
177 tags:
178 - cps-data
179 summary: Delete a data node
180 operationId: deleteDataNode
181 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000182 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
DylanB95EST30a59dd2021-11-02 17:25:18 +0000183 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
184 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
185 - $ref: 'components.yml#/components/parameters/xpathInQuery'
186 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
187 responses:
188 '204':
189 $ref: 'components.yml#/components/responses/NoContent'
190 '400':
191 $ref: 'components.yml#/components/responses/BadRequest'
DylanB95EST30a59dd2021-11-02 17:25:18 +0000192 '403':
193 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000194 '500':
195 $ref: 'components.yml#/components/responses/InternalServerError'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200196 put:
197 description: Replace a node with descendants for a given dataspace, anchor and a parent node xpath
198 tags:
199 - cps-data
200 summary: Replace a node with descendants
201 operationId: replaceNode
202 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000203 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200204 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
205 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
206 - $ref: 'components.yml#/components/parameters/xpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +0100207 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530208 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200209 requestBody:
210 required: true
211 content:
212 application/json:
213 schema:
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530214 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +0000215 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +0000216 dataSample:
217 $ref: 'components.yml#/components/examples/dataSample'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530218 application/xml:
219 schema:
220 type: object
221 xml:
222 name: stores
223 examples:
224 dataSample:
225 $ref: 'components.yml#/components/examples/dataSampleXml'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200226 responses:
227 '200':
228 $ref: 'components.yml#/components/responses/Ok'
229 '400':
230 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200231 '403':
DylanB95ESTa79c9f12021-10-29 17:33:06 +0100232 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000233 '500':
234 $ref: 'components.yml#/components/responses/InternalServerError'