OOM Offline Installer removed from conf.py
[doc.git] / docs / guides / onap-user / instantiate / instantiation / nbi / index.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0
2 .. International License. http://creativecommons.org/licenses/by/4.0
3 .. Copyright 2019 ONAP Contributors.  All rights reserved.
4
5 .. _doc_guide_user_ser_inst_nbi:
6
7
8 Service Instantiation via ONAP NBI API (TM Forum)
9 =================================================
10
11 .. warning:: The ONAP :strong:`externalapi` project is :strong:`unmaintained`.
12
13 ONAP NBI allow you to use a TM Forum standardized API (serviceOrder API).
14
15 .. Additional info in:
16 ..
17 .. .. t o c t r e e : :
18 ..   :maxdepth: 1
19 ..   :titlesonly:
20 ..
21 .. :ref:`NBI Guide<onap-externalapi-nbi:offeredapis>`
22
23
24 ONAP NBI will convert that request to ONAP SO request.
25
26
27 ServiceOrder management in NBI will support 2 modes:
28
29 * E2E integration - NBI calls SO API to perform an End-To-end integration
30 * Service-level only integration - NBI will trigger only SO request at
31   serviceInstance level (not at VNF, not at Vf-module level and nothing will
32   be created on cloud platform)
33
34 ONAP SO prerequisite: SO must be able to find a BPMN to process service
35 fulfillment (integrate VNF, VNF activation in SDNC, VF module)
36
37 The choice of the mode is done by NBI depending on information retrieved
38 in SDC. If the serviceSpecification is within a Category "E2E Service" ,
39 NBI will use E2E SO API, if not only API at service instance level
40 will be used.
41
42 There is no difference or specific expectation in the service order API
43 used by NBI user.
44
45
46 Example of serviceOrder to instantiate (=add) a service based on model
47 with id=0d463b0c-e559-4def-8d7b-df64cfbd3159
48
49
50 ::
51
52   curl -X POST \
53     http://nbi.api.simpledemo.onap.org:30274/nbi/api/v4/serviceOrder \
54     -H 'Accept: application/json' \
55     -H 'Content-Type: application/json' \
56     -H 'cache-control: no-cache' \
57     -d '{
58     "externalId": "BSS_order_001",
59     "priority": "1",
60     "description": "this is a service order to instantiate a service",
61     "category": "Consumer",
62     "requestedStartDate": "",
63     "requestedCompletionDate": "",
64     "relatedParty": [
65       {
66         "id": "JohnDoe",
67         "role": "ONAPcustomer",
68         "name": "JohnDoe"
69       }
70     ],
71     "orderItem": [
72       {
73         "id": "1",
74         "action": "add",
75         "service": {
76           "name": "my_service_model_instance_01",
77           "serviceState": "active",
78           "serviceSpecification": {
79             "id": "0d463b0c-e559-4def-8d7b-df64cfbd3159"
80           }
81         }
82       }
83     ]
84   }'
85
86 In the response, you will obtain the serviceOrderId value.
87
88 Then you have the possibility to check about the serviceorder
89 (here after the serviceOrderId=5d06309da0e46400017b1123).
90
91 This will allow you to get the serviceOrder Status (completed, failed...)
92
93 ::
94
95   curl -X GET \
96     http://nbi.api.simpledemo.onap.org:30274/nbi/api/v4/serviceOrder/5d06309da0e46400017b1123 \
97     -H 'Accept: application/json' \
98     -H 'Content-Type: application/json' \
99     -H 'cache-control: no-cache'