blob: 1e70ef60c87130c9d4c5587f4f4879c972943f8b [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'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030035 requestBody:
36 required: true
37 content:
38 application/json:
39 schema:
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +000040 type: object
41 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +000042 dataSample:
43 $ref: 'components.yml#/components/examples/dataSample'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030044 responses:
45 '201':
46 $ref: 'components.yml#/components/responses/Created'
47 '400':
48 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov0905ac12021-05-05 13:11:50 +030049 '403':
50 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +000051 '500':
52 $ref: 'components.yml#/components/responses/InternalServerError'
Renu Kumari7edbeb62021-08-30 07:45:52 -040053 put:
DylanB95ESTa79c9f12021-10-29 17:33:06 +010054 description: Replace list content under a given parent, anchor and dataspace
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030055 tags:
56 - cps-data
DylanB95ESTa79c9f12021-10-29 17:33:06 +010057 summary: Replace list content
58 operationId: replaceListContent
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030059 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +000060 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030061 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
62 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
63 - $ref: 'components.yml#/components/parameters/requiredXpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +010064 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030065 requestBody:
66 required: true
67 content:
68 application/json:
69 schema:
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +000070 type: object
71 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +000072 dataSample:
73 $ref: 'components.yml#/components/examples/dataSample'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030074 responses:
75 '200':
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +000076 $ref: 'components.yml#/components/responses/Ok'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030077 '400':
78 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov576f48e2021-05-14 14:41:05 +030079 '403':
80 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +000081 '500':
82 $ref: 'components.yml#/components/responses/InternalServerError'
lukegleeson05701dd2021-08-18 09:49:32 +010083
Rishi.Chaildacc6632021-01-27 04:27:34 +000084nodesByDataspaceAndAnchor:
niamhcore74753d92021-01-28 16:11:52 +000085 post:
Rishi.Chail6d13f162021-01-26 05:58:39 +000086 description: Create a node for a given anchor and dataspace
niamhcore74753d92021-01-28 16:11:52 +000087 tags:
88 - cps-data
Rishi.Chail6d13f162021-01-26 05:58:39 +000089 summary: Create a node
niamhcore74753d92021-01-28 16:11:52 +000090 operationId: createNode
91 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +000092 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Rishi.Chail6d13f162021-01-26 05:58:39 +000093 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
94 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
Ruslan Kashapov24bf3502021-04-19 12:40:01 +030095 - $ref: 'components.yml#/components/parameters/xpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +010096 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +053097 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
niamhcore74753d92021-01-28 16:11:52 +000098 requestBody:
99 required: true
100 content:
101 application/json:
102 schema:
Michal Jagiello6ce84d92022-12-13 07:40:19 +0000103 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +0000104 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +0000105 dataSample:
106 $ref: 'components.yml#/components/examples/dataSample'
Michal Jagiello6ce84d92022-12-13 07:40:19 +0000107 application/xml:
108 schema:
109 type: object # Workaround to show example
110 xml:
111 name: stores
112 examples:
113 dataSample:
114 $ref: 'components.yml#/components/examples/dataSampleXml'
niamhcore74753d92021-01-28 16:11:52 +0000115 responses:
Rishi.Chail6d13f162021-01-26 05:58:39 +0000116 '201':
117 $ref: 'components.yml#/components/responses/Created'
118 '400':
119 $ref: 'components.yml#/components/responses/BadRequest'
Rishi.Chail6d13f162021-01-26 05:58:39 +0000120 '403':
121 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000122 '409':
123 $ref: 'components.yml#/components/responses/Conflict'
124 '500':
125 $ref: 'components.yml#/components/responses/InternalServerError'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200126 patch:
arpitsingh2b4c4882023-03-03 21:38:57 +0530127 description: Update a data node leaves for a given dataspace and anchor and a parent node xpath. This operation
128 is currently supported for one top level data node only.
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200129 tags:
130 - cps-data
131 summary: Update node leaves
132 operationId: updateNodeLeaves
133 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000134 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200135 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
136 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
137 - $ref: 'components.yml#/components/parameters/xpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +0100138 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530139 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200140 requestBody:
141 required: true
142 content:
143 application/json:
144 schema:
Rudrangi Anupriya1decb392024-06-05 23:55:14 +0530145 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +0000146 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +0000147 dataSample:
148 $ref: 'components.yml#/components/examples/dataSample'
Rudrangi Anupriya1decb392024-06-05 23:55:14 +0530149 application/xml:
150 schema:
151 type: object
152 xml:
153 name: stores
154 examples:
155 dataSample:
156 $ref: 'components.yml#/components/examples/dataSampleXml'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200157 responses:
158 '200':
159 $ref: 'components.yml#/components/responses/Ok'
160 '400':
161 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200162 '403':
163 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000164 '500':
165 $ref: 'components.yml#/components/responses/InternalServerError'
DylanB95EST30a59dd2021-11-02 17:25:18 +0000166 delete:
167 description: Delete a datanode for a given dataspace and anchor given a node xpath.
168 tags:
169 - cps-data
170 summary: Delete a data node
171 operationId: deleteDataNode
172 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000173 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
DylanB95EST30a59dd2021-11-02 17:25:18 +0000174 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
175 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
176 - $ref: 'components.yml#/components/parameters/xpathInQuery'
177 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
178 responses:
179 '204':
180 $ref: 'components.yml#/components/responses/NoContent'
181 '400':
182 $ref: 'components.yml#/components/responses/BadRequest'
DylanB95EST30a59dd2021-11-02 17:25:18 +0000183 '403':
184 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000185 '500':
186 $ref: 'components.yml#/components/responses/InternalServerError'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200187 put:
188 description: Replace a node with descendants for a given dataspace, anchor and a parent node xpath
189 tags:
190 - cps-data
191 summary: Replace a node with descendants
192 operationId: replaceNode
193 parameters:
rajesh.kumar897686f2022-12-14 08:13:29 +0000194 - $ref: 'components.yml#/components/parameters/apiVersionInPath'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200195 - $ref: 'components.yml#/components/parameters/dataspaceNameInPath'
196 - $ref: 'components.yml#/components/parameters/anchorNameInPath'
197 - $ref: 'components.yml#/components/parameters/xpathInQuery'
aditya puthuparambil673c6d92021-08-24 17:44:34 +0100198 - $ref: 'components.yml#/components/parameters/observedTimestampInQuery'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530199 - $ref: 'components.yml#/components/parameters/contentTypeInHeader'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200200 requestBody:
201 required: true
202 content:
203 application/json:
204 schema:
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530205 type: string
puthuparambil.aditya5d8b2412021-11-24 13:35:10 +0000206 examples:
puthuparambil.adityacc17ae52022-02-25 13:24:03 +0000207 dataSample:
208 $ref: 'components.yml#/components/examples/dataSample'
Rudrangi Anupriya760dd952024-07-11 21:56:24 +0530209 application/xml:
210 schema:
211 type: object
212 xml:
213 name: stores
214 examples:
215 dataSample:
216 $ref: 'components.yml#/components/examples/dataSampleXml'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200217 responses:
218 '200':
219 $ref: 'components.yml#/components/responses/Ok'
220 '400':
221 $ref: 'components.yml#/components/responses/BadRequest'
Ruslan Kashapov24c72db2021-02-09 17:25:18 +0200222 '403':
DylanB95ESTa79c9f12021-10-29 17:33:06 +0100223 $ref: 'components.yml#/components/responses/Forbidden'
JosephKeenan909a8502022-01-28 10:02:24 +0000224 '500':
225 $ref: 'components.yml#/components/responses/InternalServerError'