shivasubedi | 8df61a9 | 2021-06-16 14:43:18 +0100 | [diff] [blame] | 1 | # ============LICENSE_START======================================================= |
puthuparambil.aditya | cc17ae5 | 2022-02-25 13:24:03 +0000 | [diff] [blame] | 2 | # Copyright (c) 2021-2022 Bell Canada. |
JosephKeenan | 909a850 | 2022-01-28 10:02:24 +0000 | [diff] [blame] | 3 | # Modifications Copyright (C) 2021-2022 Nordix Foundation |
shivasubedi | 8df61a9 | 2021-06-16 14:43:18 +0100 | [diff] [blame] | 4 | # ================================================================================ |
| 5 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | # you may not use this file except in compliance with the License. |
| 7 | # You may obtain a copy of the License at |
| 8 | # |
| 9 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | # |
| 11 | # Unless required by applicable law or agreed to in writing, software |
| 12 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | # See the License for the specific language governing permissions and |
| 15 | # limitations under the License. |
Renu Kumari | 4d52001 | 2021-08-30 11:50:43 -0400 | [diff] [blame] | 16 | # |
| 17 | # SPDX-License-Identifier: Apache-2.0 |
shivasubedi | 8df61a9 | 2021-06-16 14:43:18 +0100 | [diff] [blame] | 18 | # ============LICENSE_END========================================================= |
| 19 | |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 20 | components: |
| 21 | schemas: |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 22 | |
| 23 | AnchorDetails: |
| 24 | type: object |
| 25 | title: Anchor details by anchor Name |
| 26 | properties: |
| 27 | name: |
| 28 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 29 | example: my-anchor |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 30 | dataspaceName: |
| 31 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 32 | example: my-dataspace |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 33 | schemaSetName: |
| 34 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 35 | example: my-schema-set |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 36 | |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 37 | ErrorMessage: |
| 38 | type: object |
| 39 | title: Error |
| 40 | properties: |
| 41 | status: |
| 42 | type: string |
| 43 | message: |
| 44 | type: string |
| 45 | details: |
| 46 | type: string |
Rishi.Chail | 6d13f16 | 2021-01-26 05:58:39 +0000 | [diff] [blame] | 47 | |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 48 | MultipartFile: |
Renu Kumari | 4d52001 | 2021-08-30 11:50:43 -0400 | [diff] [blame] | 49 | type: object |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 50 | required: |
| 51 | - file |
| 52 | properties: |
Renu Kumari | 4d52001 | 2021-08-30 11:50:43 -0400 | [diff] [blame] | 53 | file: |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 54 | type: string |
| 55 | description: multipartFile |
| 56 | format: binary |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 57 | example: 'https://github.com/onap/cps/blob/master/cps-service/src/test/resources/bookstore.yang' |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 58 | |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 59 | ModuleReferences: |
| 60 | type: object |
| 61 | title: Module reference object |
| 62 | properties: |
| 63 | name: |
| 64 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 65 | example: my-module-reference-name |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 66 | namespace: |
| 67 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 68 | example: my-module-reference-namespace |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 69 | revision: |
| 70 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 71 | example: my-module-reference-revision |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 72 | |
| 73 | SchemaSetDetails: |
| 74 | type: object |
| 75 | title: Schema set details by dataspace and schemasetName |
lukegleeson | d5bda88 | 2022-03-02 14:32:47 +0000 | [diff] [blame^] | 76 | required: |
| 77 | - "moduleReferences" |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 78 | properties: |
| 79 | dataspaceName: |
| 80 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 81 | example: my-dataspace |
JosephKeenan | c6865f3 | 2021-06-08 13:16:37 +0100 | [diff] [blame] | 82 | moduleReferences: |
| 83 | type: array |
| 84 | items: |
| 85 | $ref: '#/components/schemas/ModuleReferences' |
| 86 | name: |
| 87 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 88 | example: my-schema-set |
| 89 | |
| 90 | examples: |
puthuparambil.aditya | cc17ae5 | 2022-02-25 13:24:03 +0000 | [diff] [blame] | 91 | dataSample: |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 92 | value: |
| 93 | test:bookstore: |
| 94 | bookstore-name: Chapters |
| 95 | categories: |
| 96 | - code: 01 |
| 97 | name: SciFi |
| 98 | - code: 02 |
| 99 | name: kids |
| 100 | |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 101 | parameters: |
| 102 | dataspaceNameInQuery: |
| 103 | name: dataspace-name |
| 104 | in: query |
| 105 | description: dataspace-name |
| 106 | required: true |
| 107 | schema: |
| 108 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 109 | example: my-dataspace |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 110 | dataspaceNameInPath: |
| 111 | name: dataspace-name |
| 112 | in: path |
| 113 | description: dataspace-name |
| 114 | required: true |
| 115 | schema: |
| 116 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 117 | example: my-dataspace |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 118 | anchorNameInPath: |
| 119 | name: anchor-name |
| 120 | in: path |
| 121 | description: anchor-name |
| 122 | required: true |
| 123 | schema: |
| 124 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 125 | example: my-anchor |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 126 | schemaSetNameInQuery: |
| 127 | name: schema-set-name |
| 128 | in: query |
| 129 | description: schema-set-name |
| 130 | required: true |
| 131 | schema: |
| 132 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 133 | example: my-schema-set |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 134 | schemaSetNameInPath: |
| 135 | name: schema-set-name |
| 136 | in: path |
| 137 | description: schema-set-name |
| 138 | required: true |
| 139 | schema: |
| 140 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 141 | example: my-schema-set |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 142 | anchorNameInQuery: |
| 143 | name: anchor-name |
| 144 | in: query |
| 145 | description: anchor-name |
| 146 | required: true |
| 147 | schema: |
| 148 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 149 | example: my-anchor |
Ruslan Kashapov | 2098392 | 2021-02-01 10:47:25 +0200 | [diff] [blame] | 150 | xpathInQuery: |
Ruslan Kashapov | 24c72db | 2021-02-09 17:25:18 +0200 | [diff] [blame] | 151 | name: xpath |
Ruslan Kashapov | 2098392 | 2021-02-01 10:47:25 +0200 | [diff] [blame] | 152 | in: query |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 153 | description: For more details on xpath, please refer https://docs.onap.org/projects/onap-cps/en/latest/cps-path.html |
Ruslan Kashapov | 2098392 | 2021-02-01 10:47:25 +0200 | [diff] [blame] | 154 | required: false |
| 155 | schema: |
| 156 | type: string |
| 157 | default: / |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 158 | examples: |
| 159 | container xpath: |
| 160 | value: /shops/bookstore |
| 161 | list attributes xpath: |
| 162 | value: /shops/bookstore/categories[@code=1] |
Ruslan Kashapov | 0905ac1 | 2021-05-05 13:11:50 +0300 | [diff] [blame] | 163 | requiredXpathInQuery: |
| 164 | name: xpath |
| 165 | in: query |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 166 | description: For more details on xpath, please refer https://docs.onap.org/projects/onap-cps/en/latest/cps-path.html |
Ruslan Kashapov | 0905ac1 | 2021-05-05 13:11:50 +0300 | [diff] [blame] | 167 | required: true |
| 168 | schema: |
| 169 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 170 | examples: |
| 171 | container xpath: |
| 172 | value: /shops/bookstore |
| 173 | list attributes xpath: |
| 174 | value: /shops/bookstore/categories[@code=1] |
niamhcore | 53f07ac | 2021-02-19 13:14:40 +0000 | [diff] [blame] | 175 | cpsPathInQuery: |
| 176 | name: cps-path |
| 177 | in: query |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 178 | description: For more details on cps path, please refer https://docs.onap.org/projects/onap-cps/en/latest/cps-path.html |
niamhcore | 53f07ac | 2021-02-19 13:14:40 +0000 | [diff] [blame] | 179 | required: false |
| 180 | schema: |
| 181 | type: string |
| 182 | default: / |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 183 | examples: |
| 184 | container cps path: |
| 185 | value: //bookstore |
| 186 | list attributes cps path: |
| 187 | value: //categories[@code=1] |
Ruslan Kashapov | 2098392 | 2021-02-01 10:47:25 +0200 | [diff] [blame] | 188 | includeDescendantsOptionInQuery: |
| 189 | name: include-descendants |
| 190 | in: query |
| 191 | description: include-descendants |
| 192 | required: false |
| 193 | schema: |
| 194 | type: boolean |
| 195 | default: false |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 196 | example: false |
aditya puthuparambil | 673c6d9 | 2021-08-24 17:44:34 +0100 | [diff] [blame] | 197 | observedTimestampInQuery: |
| 198 | name: observed-timestamp |
| 199 | in: query |
| 200 | description: observed-timestamp |
| 201 | required: false |
| 202 | schema: |
| 203 | type: string |
| 204 | example: '2021-03-21T00:10:34.030-0100' |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 205 | |
| 206 | responses: |
| 207 | NotFound: |
| 208 | description: The specified resource was not found |
| 209 | content: |
| 210 | application/json: |
| 211 | schema: |
| 212 | $ref: '#/components/schemas/ErrorMessage' |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 213 | example: |
| 214 | status: 404 |
| 215 | message: Resource Not Found |
| 216 | details: The requested resource is not found |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 217 | Unauthorized: |
| 218 | description: Unauthorized |
| 219 | content: |
| 220 | application/json: |
| 221 | schema: |
| 222 | $ref: '#/components/schemas/ErrorMessage' |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 223 | example: |
| 224 | status: 401 |
| 225 | message: Unauthorized request |
| 226 | details: This request is unauthorized |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 227 | Forbidden: |
| 228 | description: Forbidden |
| 229 | content: |
| 230 | application/json: |
| 231 | schema: |
| 232 | $ref: '#/components/schemas/ErrorMessage' |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 233 | example: |
| 234 | status: 403 |
| 235 | message: Request Forbidden |
| 236 | details: This request is forbidden |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 237 | BadRequest: |
| 238 | description: Bad Request |
| 239 | content: |
| 240 | application/json: |
| 241 | schema: |
| 242 | $ref: '#/components/schemas/ErrorMessage' |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 243 | example: |
| 244 | status: 400 |
| 245 | message: Bad Request |
| 246 | details: The provided request is not valid |
Ruslan Kashapov | dce4e31 | 2021-01-11 15:34:10 +0200 | [diff] [blame] | 247 | Conflict: |
| 248 | description: Conflict |
| 249 | content: |
| 250 | application/json: |
| 251 | schema: |
| 252 | $ref: '#/components/schemas/ErrorMessage' |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 253 | example: |
| 254 | status: 409 |
| 255 | message: Conflicting request |
| 256 | details: The request cannot be processed as the resource is in use. |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 257 | Ok: |
| 258 | description: OK |
| 259 | content: |
| 260 | application/json: |
| 261 | schema: |
| 262 | type: object |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 263 | examples: |
puthuparambil.aditya | cc17ae5 | 2022-02-25 13:24:03 +0000 | [diff] [blame] | 264 | dataSample: |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 265 | value: "" |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 266 | Created: |
| 267 | description: Created |
| 268 | content: |
| 269 | text/plain: |
| 270 | schema: |
| 271 | type: string |
puthuparambil.aditya | 5d8b241 | 2021-11-24 13:35:10 +0000 | [diff] [blame] | 272 | example: my-resource |
JosephKeenan | 909a850 | 2022-01-28 10:02:24 +0000 | [diff] [blame] | 273 | InternalServerError: |
| 274 | description: Internal Server Error |
| 275 | content: |
| 276 | application/json: |
| 277 | schema: |
| 278 | $ref: "#/components/schemas/ErrorMessage" |
| 279 | example: |
| 280 | status: 500 |
| 281 | message: Internal Server Error |
| 282 | details: Internal Server Error occurred |
puthuparambil.aditya | 001e773 | 2021-01-13 12:06:20 +0000 | [diff] [blame] | 283 | NoContent: |
| 284 | description: No Content |
| 285 | content: {} |