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: "Request the instantiation of a service\n\nA Service Order is a type\
17 \ of order which can be used to describe a group of operations on service – one\
18 \ service order item per service. An action at the level of the service order\
19 \ item describe the operation to be done on a service (add, terminate for example).\
20 \ The service order is triggered from the BSS system in charge of the product\
21 \ order management to ONAP that will manage the service fulfillment.\n\nList of\
22 \ available subscription for serviceOrdering notifications, see /hub resources\
23 \ for more information:\n\n- ServiceOrderCreationNotification\n- ServiceOrderStateChangeNotification\n\
24 - ServiceOrderItemStateChangeNotification\n\n"
26 title: "API ServiceOrder"
28 url: "/redoc/logo.png"
29 backgroundColor: "#FFFFFF"
30 host: "localhost:8080"
31 basePath: "/nbi/api/v4"
35 - "application/json;charset=utf-8"
37 - name: "ServiceOrder"
38 description: "provided by NBI"
39 - name: "Notification"
40 description: "provided by subscribers, which MUST registered by creating a hub resource"
47 - "application/json;charset=utf-8"
49 - "application/json;charset=utf-8"
50 operationId: "serviceOrderCreate"
51 summary: "Create a service order"
52 description: "This operation creates a service order entity.\nThe TMF Open API\
53 \ specification document provides the list of mandatory and non mandatory\
54 \ attributes when creating a ServiceOrder, including any possible rule conditions\
55 \ and applicable default values.\nPOST should be used without specifying the\
56 \ id and the href, the Service Order Management system is in charge of generating\
57 \ the id + href for the ServiceOrder.\n\nIn Beijing Release, NBI will use\
58 \ only POST {{url}}/ecomp/mso/infra/serviceInstances/v4 SO API. This mean\
59 \ that only the 'service-instance' level will be created in AAI. Additional\
60 \ resource like VNF and/OR VF are not created.\n\nIn Casablanca release, NBI\
61 \ has been improved to also be able to use POST {{url}}/e2eServiceInstances/v3\
62 \ SO API. This API is able to instantiate in ONAP E2E service; This is useful\
63 \ for CCVPN and VoLTE UC.\nDepending on the service category defined in SDC,\
64 \ NBI will use one or the other SO API. If category starts with e2e, NBI will\
65 \ use {url}}/e2eServiceInstances/v3 SO API - else it will use {{url}}/ecomp/mso/infra/serviceInstances/v4\
69 - name: "serviceOrder"
74 $ref: "#/definitions/CreateServiceOrder"
82 description: "Created"
84 $ref: "#/definitions/ServiceOrder"
89 - "application/json;charset=utf-8"
90 operationId: "serviceOrderFind"
91 summary: "List service orders"
92 description: "Retrieve and list service order entities according to given criteria.\n\
93 Only a predefined set of attribute is proposed.\nAttribute selection could\
94 \ be described in the fields attribute."
105 description: "state of the order(s) to be retrieved"
107 - name: "description"
112 - name: "orderDate.gt"
115 description: "order date greather than"
117 - name: "orderDate.lt"
120 description: "order date lower than"
125 description: "this attribute could be used to filter retrieved attribute(s)\
131 description: "The index of the first element to retrieve. Zero is the first\
132 \ element of the collection."
138 description: "The maximum number of elements to retrieve (it can be greater\
139 \ than the actual available number of items)."
148 $ref: "#/definitions/ServiceOrder"
163 - "application/json;charset=utf-8"
164 operationId: "serviceOrderGet"
165 summary: "Retrieve a service order"
166 description: "This operation retrieves a service order entity. \nAttribute selection\
167 \ is enabled for all first level attributes."
178 description: "Attribute selection"
189 $ref: "#/definitions/ServiceOrder"
195 - "application/json;charset=utf-8"
197 - "application/json;charset=utf-8"
198 operationId: "notificationCreate"
199 summary: "NBI will send notification to this operation provided by subscribers"
200 description: "Notification structure depends of the eventType:\n\n- ServiceOrderCreationNotification\n\
201 - ServiceOrderStateChangeNotification\n\n```\n{\n \"eventId\": \"string\"\
202 ,\n \"eventDate\": \"2019-03-12T16:21:27.530Z\",\n \"eventType\": \"string\"\
203 ,\n \"event\": {\n \"id\": \"string\",\n \"href\": \"string\",\n \
204 \ \"externalId\": \"string\",\n \"state\": \"acknowledged\",\n \"orderDate\"\
205 : \"2019-03-12T16:21:27.530Z\",\n \"completionDateTime\": \"2019-03-12T16:21:27.530Z\"\
206 \n }\n}\n```\n\n- ServiceOrderItemStateChangeNotification\n\n```\n{\n \"\
207 eventId\": \"string\",\n \"eventDate\": \"2019-03-12T16:21:44.066Z\",\n \
208 \ \"eventType\": \"string\",\n \"event\": {\n \"id\": \"string\",\n \
209 \ \"href\": \"string\",\n \"externalId\": \"string\",\n \"state\":\
210 \ \"acknowledged\",\n \"orderDate\": \"2019-03-12T16:21:44.066Z\",\n \
211 \ \"completionDateTime\": \"2019-03-12T16:21:44.066Z\",\n \"orderItem\"\
212 : [\n {\n \"id\": \"string\",\n \"action\": \"add\",\n\
213 \ \"state\": \"acknowledged\",\n \"service\": {\n \"\
214 id\": \"string\",\n \"href\": \"string\",\n \"name\": \"\
215 string\",\n \"serviceState\": \"string\",\n \"serviceCharacteristic\"\
216 : [\n {\n \"name\": \"string\",\n \"\
217 valueType\": \"string\",\n \"value\": {\n \"serviceCharacteristicValue\"\
218 : \"string\"\n }\n }\n ],\n \"serviceRelationship\"\
219 : [\n {\n \"type\": \"reliesOn\"\n }\n\
220 \ ],\n \"relatedParty\": [\n {\n \
221 \ \"id\": \"string\",\n \"href\": \"string\",\n \
222 \ \"role\": \"string\",\n \"name\": \"string\",\n \
223 \ \"@referredType\": \"string\"\n }\n ],\n \
224 \ \"serviceSpecification\": {\n \"id\": \"string\",\n \
225 \ \"href\": \"string\",\n \"name\": \"string\",\n \
226 \ \"version\": \"string\",\n }\n }\n }\n ]\n }\n\
230 - name: "Notification"
235 $ref: "#/definitions/Notification"
243 description: "Created"
245 $ref: "#/definitions/Notification"
248 description: "Action type to be describer on the order item.\nmodify is not managed\
249 \ in Beijing release"
257 description: "List of possible state for the order and the orderItem."
270 description: "Relationship type;\nOnly reliesOn is managed in Beijing release."
278 - "ServiceOrderCreationNotification"
279 - "ServiceOrderStateChangeNotification"
280 - "ServiceOrderItemStateChangeNotification"
295 description: "Application related code (as defined in the API or from a common\
300 description: "Text that explains the reason for error. This can be shown to\
304 description: "Text that provide more details and corrective actions related\
305 \ to the error. This can be shown to a client user"
308 description: "http error code extension like 400-2"
311 description: "url pointing to documentation describing the error"
314 description: "Linked Services to the one instantiate\nnbi component used this\
315 \ relationship to sort request to ONAP."
322 $ref: "#/definitions/RelationshipType"
324 $ref: "#/definitions/Service"
326 description: "Service references"
332 description: "Unique identifier of the service"
335 description: "Reference of the service"
337 ServiceCharacteristic:
338 description: "ServiceCharacteristic"
344 description: "Name of characteristic"
350 $ref: "#/definitions/Value"
352 description: "A related party defines party which are involved in this order and\
353 \ the role they are playing.\nfor Beijing release:\nWith the current version\
354 \ of APIs used from SO and AAI we need to manage a ‘customer’. This customer\
355 \ concept is confusing with Customer BSS concept. We took the following rules\
356 \ to manage the ‘customer’ information:\no\tIt could be provided through a serviceOrder\
357 \ in the service Order a relatedParty with role ‘ONAPcustomer’ should be provided\
358 \ in the serviceOrder header (we will not consider in this release the party\
359 \ at item level); External API component will check if this customer exists\
360 \ and create it in AAI if not.\no\tIf no relatedParty are provided the service\
361 \ will be affected to ‘generic’ customer (dummy customer) – we assume this ‘\
362 generic’ customer always exists."
369 description: "Unique identifier of a related party"
372 description: "An hyperlink to the party - not used in Beijnig release"
375 description: "The role of the related party (e.g. Owner, requester, fullfiller\
376 \ etc).\nONLY 'ONAPcustomer' is considered"
379 description: "Name of the related party"
384 ServiceSpecificationRef:
385 description: "The service specification (these attributes are fetched from the\
392 description: "Unique identifier of the service specification\nThis information\
393 \ will be used to retrieve SDC information + mapped to SO ModelNameVersionIdin\
397 description: "Reference of the service specification\nNot used in Beijing\
401 description: "Name of the service specification\nNot used in Beijing release"
404 description: "Version of the service Specification\nNot used in Beijing release"
407 $ref: "#/definitions/TargetServiceSchema"
409 description: "Not used in Beijing release"
412 description: "Not used in Beijing release"
415 description: "Not used in Beijing release"
418 description: "Service (to be added, modified, deleted) description"
424 description: "Identifier of a service instance.\nIt must be valued if orderItem\
425 \ action is 'delete' and corresponds to a AAI service.id"
428 description: "Reference to the Service (useful for delete or modify command).\n\
429 Not managed in Beijing release."
432 description: "Name of the service - When orderItem action is 'add' this name\
433 \ will be used in ONAP/SO request as InstaceName."
436 description: "The lifecycle state of the service requested;\nNot managed in\
440 description: "To define the service type\nNot managed in Beijing Release"
443 description: "The URL to get the resource schema.\nNot managed in Beijing\
446 serviceCharacteristic:
449 $ref: "#/definitions/ServiceCharacteristic"
453 $ref: "#/definitions/ServiceRelationship"
457 $ref: "#/definitions/RelatedParty"
458 serviceSpecification:
459 $ref: "#/definitions/ServiceSpecificationRef"
460 OrderItemRelationship:
461 description: "Linked order item to the one containing this attribute.\nnbi component\
462 \ used this relationship to sort request to ONAP."
469 $ref: "#/definitions/RelationshipType"
471 description: "Unique identifier of an order item"
474 description: "An identified part of the order. A service order is decomposed into\
475 \ one or more order items."
482 description: "Identifier of the line item (generally it is a sequence number\
486 $ref: "#/definitions/ActionType"
488 $ref: "#/definitions/StateType"
490 description: "Progress of the delivery in percentage."
493 description: "Used to extend the order item.\nnot used in Beijing relase"
496 description: "not used in Beijing relase"
499 description: "not used in Beijing relase"
501 orderItemRelationship:
504 $ref: "#/definitions/OrderItemRelationship"
506 $ref: "#/definitions/Service"
510 $ref: "#/definitions/OrderMessage"
512 description: "A Service Order is a type of order which can be used to place an\
513 \ order between a customer and a service provider or between a service provider\
514 \ and a partner and vice versa"
520 description: "ID created on repository side"
523 description: "Hyperlink to access the order"
526 description: "ID given by the consumer and only understandable by him (to\
527 \ facilitate his searches)"
530 description: "A way that can be used by consumers to prioritize orders in\
531 \ Service Order Management system (from 0 to 4 : 0 is the highest priority,\
535 description: "A free-text description of the service order"
538 description: "Used to categorize the order that can be useful for the OM system\
539 \ (e.g. “broadband”, “TVOption”, ...)"
542 $ref: "#/definitions/StateType"
548 description: "Date when the order was completed"
552 description: "Order start date wished by the requestor"
555 requestedCompletionDate:
556 description: "Requested delivery date from the requestor perspective"
559 expectedCompletionDate:
564 description: "Date when the order was started for processing"
579 $ref: "#/definitions/RelatedParty"
583 $ref: "#/definitions/OrderRelationship"
587 $ref: "#/definitions/ServiceOrderItem"
591 $ref: "#/definitions/OrderMessage"
593 description: "Linked order to the one containing this attribute.\nThis relationship\
594 \ is not used to sort ONAP request."
600 description: "The type of related order, can be : “dependency” if the order\
601 \ needs to be “not started” until another order item is complete (a service\
602 \ order in this case) or “cross-ref” to keep track of the source order (a\
606 description: "The id of the related order"
609 description: "A hyperlink to the related order"
612 description: "Type of the referred order."
615 description: "Target to the schema describing the service spec resource"
622 description: "Indicates the (class) type of resource."
625 description: "This field provided a link to the schema describing this REST\
629 description: "Value is a descriptive structure for service characteristic"
632 serviceCharacteristicValue:
633 description: "Value of the characteristic."
635 CreateServiceOrderItem:
636 description: "This structure is used in the operation POST for a serviceOrder\
637 \ request to describe an item.\nAttribute description is not accurate and should\
638 \ be find in the serviceOrderItem class."
645 description: "Identifier of the line item (generally it is a sequence number\
649 $ref: "#/definitions/ActionType"
650 orderItemRelationship:
653 $ref: "#/definitions/OrderItemRelationship"
655 $ref: "#/definitions/Service"
657 description: "This structure is used in the operation POST for a serviceOrder\
658 \ request.\nAttribute description is not accurate and should be find in the\
659 \ serviceOrder class."
663 description: "ID given by the consumer and only understandable by him (to\
664 \ facilitate his searches)"
667 description: "A way that can be used by consumers to prioritize orders in\
668 \ Service Order Management system (from 0 to 4 : 0 is the highest priority,\
672 description: "A free-text description of the service order"
675 description: "Used to categorize the order that can be useful for the OM system\
676 \ (e.g. “broadband”, “TVOption”, ...)"
679 description: "Order start date wished by the requestor"
682 requestedCompletionDate:
683 description: "Requested delivery date from the requestor perspective"
689 $ref: "#/definitions/RelatedParty"
693 $ref: "#/definitions/OrderRelationship"
697 $ref: "#/definitions/CreateServiceOrderItem"
699 description: "This structure is used to provide a subset of serviceOrder attributes\
700 \ to be provided in particular for notification messages"
706 description: "ID created on repository side"
709 description: "Hyperlink to access the order"
712 description: "ID given by the consumer and only understandable by him (to\
713 \ facilitate his searches)"
716 $ref: "#/definitions/StateType"
722 description: "Date when the order was completed"
726 description: "Notification structure for a serviceOrdering notification"
742 $ref: "#/definitions/EventType"
744 $ref: "#/definitions/ServiceOrderSummaryWithItem"
745 ServiceOrderItemSummary:
746 description: "Service Order item summary to be used for notification"
753 description: "Identifier of the line item (generally it is a sequence number\
757 $ref: "#/definitions/ActionType"
759 $ref: "#/definitions/StateType"
761 $ref: "#/definitions/Service"
762 ServiceOrderSummaryWithItem:
763 description: "Service order item summary with item description"
769 description: "ID created on repository side"
772 description: "Hyperlink to access the order"
775 description: "ID given by the consumer and only understandable by him (to\
776 \ facilitate his searches)"
779 $ref: "#/definitions/StateType"
785 description: "Date when the order was completed"
791 $ref: "#/definitions/ServiceOrderItemSummary"
793 description: "An optional array of messages associated with the Order"
796 - "correctionRequired"
800 description: "A code associated to this message"
803 description: "Service Order attribute related to this error message"
806 description: "Message related to this order"
809 $ref: "#/definitions/SeverityMessage"
811 description: "Indicator that an action is required to allow service order\
812 \ fullfilment to follow up"