1 # Copyright (c) 2018 Orange
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.swagger: "2.0"
16 description: "serviceCatalog API designed for ONAP Beijing Release.\nThis API is\
17 \ build from TMF open API17.5. \nOnly operation GET (by id & byList) for resource\
18 \ serviceSpecification is available\n\n"
20 title: "API ServiceCatalog"
22 url: "/redoc/logo.png"
23 backgroundColor: "#FFFFFF"
25 basePath: "/nbi/api/v1"
29 - "application/json;charset=utf-8"
31 - name: "ServiceSpecification"
34 /serviceSpecification:
37 - "ServiceSpecification"
39 - "application/json;charset=utf-8"
40 operationId: "serviceSpecificationFind"
41 summary: "List service specifications"
42 description: "This operation returns service specifications from a catalog.\n\
43 Only a predefined set of attribute is proposed : Based on SDC limitations,\
44 \ only attributes category and distributionStatus are available for serviceSpecification\
45 \ filtering\nFields attribute could be used to filter attributes retrieved"
51 description: "Field selection - used to filtering the attributes to be retreived"
56 description: "Service Category (filter)"
58 - name: "distributionStatus"
61 description: "Service distribution status (filter)"
69 $ref: "#/definitions/ServiceSpecification"
71 description: "Bad Request\n\nList of supported error codes:\n- 20: Invalid\
72 \ URL parameter value\n- 21: Missing body\n- 22: Invalid body\n- 23: Missing\
73 \ body field\n- 24: Invalid body field\n- 25: Missing header\n- 26: Invalid\
74 \ header value\n- 27: Missing query-string parameter\n- 28: Invalid query-string\
77 $ref: "#/definitions/ErrorRepresentation"
79 description: "Unauthorized\n\nList of supported error codes:\n- 40: Missing\
80 \ credentials\n- 41: Invalid credentials\n- 42: Expired credentials"
82 $ref: "#/definitions/ErrorRepresentation"
84 description: "Forbidden\n\nList of supported error codes:\n- 50: Access\
85 \ denied\n- 51: Forbidden requester\n- 52: Forbidden user\n- 53: Too many\
88 $ref: "#/definitions/ErrorRepresentation"
90 description: "Not Found\n\nList of supported error codes:\n- 60: Resource\
93 $ref: "#/definitions/ErrorRepresentation"
95 description: "Unprocessable entity\n\nFunctional error"
97 $ref: "#/definitions/ErrorRepresentation"
99 description: "Internal Server Error\n\nList of supported error codes:\n\
102 $ref: "#/definitions/ErrorRepresentation"
104 description: "Service Unavailable\n\nList of supported error codes:\n- 5:\
105 \ The service is temporarily unavailable\n- 6: Orange API is over capacity,\
108 $ref: "#/definitions/ErrorRepresentation"
109 /serviceSpecification/{id}:
112 - "ServiceSpecification"
114 - "application/json;charset=utf-8"
115 operationId: "serviceSpecificationGet"
116 summary: "Retrieve a service specification"
117 description: "This operation returns a service specification by its id from\
118 \ a catalog. Attribute selection is enabled using the fields attribute."
128 description: "Attribute selection"
134 $ref: "#/definitions/ServiceSpecification"
136 description: "Bad Request\n\nList of supported error codes:\n- 20: Invalid\
137 \ URL parameter value\n- 21: Missing body\n- 22: Invalid body\n- 23: Missing\
138 \ body field\n- 24: Invalid body field\n- 25: Missing header\n- 26: Invalid\
139 \ header value\n- 27: Missing query-string parameter\n- 28: Invalid query-string\
142 $ref: "#/definitions/ErrorRepresentation"
144 description: "Unauthorized\n\nList of supported error codes:\n- 40: Missing\
145 \ credentials\n- 41: Invalid credentials\n- 42: Expired credentials"
147 $ref: "#/definitions/ErrorRepresentation"
149 description: "Forbidden\n\nList of supported error codes:\n- 50: Access\
150 \ denied\n- 51: Forbidden requester\n- 52: Forbidden user\n- 53: Too many\
153 $ref: "#/definitions/ErrorRepresentation"
155 description: "Not Found\n\nList of supported error codes:\n- 60: Resource\
158 $ref: "#/definitions/ErrorRepresentation"
160 description: "Unprocessable entity\n\nFunctional error"
162 $ref: "#/definitions/ErrorRepresentation"
164 description: "Internal Server Error\n\nList of supported error codes:\n\
167 $ref: "#/definitions/ErrorRepresentation"
169 description: "Service Unavailable\n\nList of supported error codes:\n- 5:\
170 \ The service is temporarily unavailable\n- 6: Orange API is over capacity,\
173 $ref: "#/definitions/ErrorRepresentation"
175 LifecycleStatusValues:
176 description: "Service lifecycle value from ONAP SDC"
179 - "NOT_CERTIFIED_CHECKOUT"
180 - "NOT_CERTIFIED_CHECKIN"
181 - "READY_FOR_CERTIFICATION"
182 - "CERTIFICATION_IN_PROGRESS"
185 description: "Service distribution status from ONAP."
188 - "DISTRIBUTION_NOT_APPROVED"
189 - "DISTRIBUTION_APPROVED"
191 - "DISTRIBUTION_REJECTED"
193 description: "This class is used to describe error.\nfor nbi Beijing release we\
194 \ do not manage additional error for serviceCatalog"
201 description: "Application related code (as defined in the API or from a common\
206 description: "Text that explains the reason for error. This can be shown to\
210 description: "Text that provide more details and corrective actions related\
211 \ to the error. This can be shown to a client user"
214 description: "http error code extension like 400-2"
217 description: "url pointing to documentation describing the error"
220 description: "The class type of a REST resource."
223 description: "it provides a link to the schema describing a REST resource."
226 description: "A time period"
230 description: "Start date and time of the period"
234 description: "End date and time of the period"
238 description: "Party linked to the service catalog.\nin nbi we retrieve information\
239 \ about last updater of the service in SDC"
243 description: "Unique identifier of the related party. Filled with lastUpdaterUserId"
246 description: "Role payed by the related party\nOnly role 'lastUpdater' is\
247 \ retrieved in Beijing release"
250 description: "Name of the related party - Filled with lastUpdatedFullName"
252 ServiceSpecification:
253 description: "ServiceSpecification is a class that offers characteristics to describe\
254 \ a type of service. Functionally, it acts as a template by which Services may\
255 \ be instantiated. By sharing the same specification, these services would therefore\
256 \ share the same set of characteristics.\nthe service information are retrieved\
263 description: "Unique identifier of the service specification. Filled with\
267 description: "Reference of the service specification- not mapped in Beijing"
270 description: "Name of the service specification- Filled with SDC Service name"
273 description: "A narrative that explains in detail what the service specification\
274 \ is - Filled with SDC Service description"
277 description: "This attribute allows to dynamically extends TMF class. Valued\
278 \ with 'ONAPservice'. We used this features to add following attributes:\n\
279 invariantUUID\ntoscaModelURL\ntoscaResourceName\ncategory (1)\nsubcategory\
280 \ (1)\ndistributionStatus"
282 default: "ONAPservice"
284 description: "Not used for Beijing release"
287 description: "Not used for Beijing release"
290 description: "Additional attribute (not in the TMF API) - extended through\
291 \ @type - invariantUUID"
294 description: "Additional attribute (not in the TMF API) - extended through\
295 \ @type - toscaModelURL"
298 description: "Additional attribute (not in the TMF API) - extended through\
299 \ @type - toscaResourceName"
302 description: "Additional attribute - extended through @type - category\nPlease\
303 \ note that this attribute is managed in TMF - in future release we'll introduce\
307 description: "Additional attribute - extended through @type - category\nPlease\
308 \ note that this attribute is managed in TMF - in future release we'll introduce\
312 $ref: "#/definitions/DistributionStatus"
314 description: "Service specification version - Filled with SDC Service version"
317 $ref: "#/definitions/LifecycleStatusValues"
319 $ref: "#/definitions/TargetServiceSchemaRef"
323 $ref: "#/definitions/Attachment"
327 $ref: "#/definitions/RelatedPartyRef"
328 resourceSpecification:
331 $ref: "#/definitions/ResourceSpecificationRef"
332 serviceSpecCharacteristic:
335 $ref: "#/definitions/ServiceSpecCharacteristic"
336 ServiceSpecCharacteristic:
337 description: "A characteristic quality or distinctive feature of a ServiceSpecification.\
338 \ \nServiceSpecCharacteristic are retrieved in the serviceTosca file in the\
339 \ topology_template section in the inputs section."
343 description: "Name of the characteristic - Filled with parameter_name"
346 description: "A narrative that explains in detail what the characteristic\
347 \ is - Filled with parameter_description"
350 description: "A kind of value that the characteristic can take on, such as\
351 \ numeric, text and so forth - Filled with parameter_type"
354 description: "This attribute allows to dynamically extends TMF class. Valued\
355 \ with: 'ONAPserviceCharacteristic'. We do not used this features in nbi\
359 description: "An url pointing to type description - we do not use it in nbi\
363 description: "A parameter to define if the characteristic is mandatory - Filled\
364 \ from parameter_required – if not fielded by default ‘true’"
368 description: "Status of the characteristic - filled with status_value"
370 serviceSpecCharacteristicValue:
373 $ref: "#/definitions/ServiceSpecCharacteristicValue"
375 description: "An attachment is a file uses to describe the service.\nIn nbi we\
376 \ use attachment to retrieve ONAP artifacts."
380 description: "Unique identifier of the attachment - filled with artifactUUID."
383 description: "Name of the attachment - filled with artifactName"
386 description: "Description of the attachment - filled with artifactDescription"
389 description: "This attribute allows to dynamically extends TMF class. Valued\
390 \ with 'ONAPartifact'. We used this features to add following attributes:\
391 \ \nartifactLabel\nartifactGroupType\nartifactTimeout\nartifactChecksum\n\
392 artifactVersion\ngeneratedFromUUID"
394 default: "ONAPartifact"
396 description: "Additional attribute (not in the TMF API) - extended through\
397 \ @type - artifactLabel"
400 description: "Additional attribute (not in the TMF API) - extended through\
401 \ @type - artifactGroupType"
404 description: "Additional attribute (not in the TMF API) - extended through\
405 \ @type - artifactTimeout"
408 description: "Additional attribute (not in the TMF API) - extended through\
409 \ @type - artifactChecksum"
412 description: "Additional attribute (not in the TMF API) - extended through\
413 \ @type - artifactVersion"
416 description: "Additional attribute (not in the TMF API) - extended through\
417 \ @type - generatedFromUUID"
420 description: "Uniform Resource Locator, is a web page address - filled with\
424 description: "Filled with artifactType"
426 ServiceSpecCharacteristicValue:
427 description: "A number or text that can be assigned to a service specification\
428 \ characteristic.\nServiceSpecCharacteristicValue are retrieved in the service\
433 description: "A kind of value that the characteristic can take on, such as\
434 \ numeric, text, and so forth\nRetrieved in the Tosca in the topology_template\
435 \ section in the inputs section - parameter_type. \nWe do not manage parameter_type=\
436 \ list or map for Beijing release"
439 description: "Information calculated from parameter default in the Tosca file"
442 description: "A discrete value that the characteristic can take on"
444 ResourceSpecificationRef:
445 description: "A list of resourceSpec identified to deliver the service.\nfor nbi\
446 \ we retrieve resource information available in service description (through\
447 \ SDC api) bu as well information retrieved in the TOSCA file."
451 description: "Unique identifier of the resource specification - filled with\
455 description: "Version for this resource specification - filled with resourceVersion"
458 description: "Name of the resource specification - filled with resourceName"
461 description: "This attribute allows to dynamically extends TMF class. Valued\
462 \ with: 'ONAPresource'. We used this features to add following attributes:\n\
463 resourceInstanceName\nresourceInvariantUUID\nresourceType\nmodelCustomizationName\n\
464 modelCustomizationId"
466 default: "ONAPresource"
467 resourceInstanceName:
468 description: "Additional attribute (not in the TMF API) - extended through\
469 \ @type - resourceInstanceName"
471 resourceInvariantUUID:
472 description: "Additional attribute (not in the TMF API) - extended through\
473 \ @type - resourceInvariantUUID"
476 description: "Additional attribute (not in the TMF API) - extended through\
477 \ @type - resoucreType"
479 modelCustomizationName:
480 description: "Additional attribute (not in the TMF API) - extended through\
481 \ @type - Retrieved in the TOSCA file : attribute name in topology_template/node_template\
484 modelCustomizationId:
485 description: "Additional attribute (not in the TMF API) - extended through\
486 \ @type - Retrieved in the TOSCA file : attribute customizationUUID in topology_template/node_template\
489 TargetServiceSchemaRef: