Merge "Update the documentation"
[nonrtric.git] / docs / api-docs.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. http://creativecommons.org/licenses/by/4.0
3
4
5 ========
6 API-Docs
7 ========
8
9 This is the API-docs of Non-RT RIC.
10
11 .. contents::
12    :depth: 3
13    :local:
14
15 The Non-RT RIC consists of four parts, described in the sections below:
16  * The Dashboard
17  * The Policy Agent
18  * The Near-RT RIC simulator
19  * The Sdnc A1 Controller
20
21 Dashboard
22 =========
23
24 The Non-RT RIC dashboard is an interface that allows human users to create, edit and delete policy instances, for each existing policy type. The policy types are owned by the Near-RT RIC, Non-RT RIC can just query them, so it's not possible to act on them.
25
26 See the README.md file in the nonrtric/dashboard repo for info about how to use it.
27
28 API Functions
29 -------------
30
31 To run the dashboard locally, you can follow these steps:
32
33 - Fetch the latest code from `gerrit`_
34
35 .. _gerrit: https://gerrit.nordix.org/c/oransc/nonrtric/+/2747/
36
37 - Before compiling, run the following commands::
38
39     git submodule init
40
41     git submodule update
42
43 - Start the backend (you might have to build it first)::
44
45     mvn clean install
46
47     mvn -Dorg.oransc.ric.portal.dashboard=mock -Dtest=DashboardTestServer -DfailIfNoTests=false test
48
49
50 - Now you can open URL:  `localhost:8080`_ in a browser.
51
52 .. _localhost:8080: localhost:8080
53
54 From the main page, click on the "Policy Control" card. From here, it is possible to create or list instances for each existing policy type.
55
56 When the instances are listed, it is possible to edit or delete each instance from the expanded view.
57
58 .. image:: ./images/non-RT_RIC_dashboard.png
59
60 Policy Agent
61 ============
62 The Policy Agent provides common functionality useful for R-Apps, for instance:
63  * A repository of available Near-T RICs, their policy types and policy instances.
64  * An A1 connection to he Near-RT RICs.
65
66 See the README.md file in the nonrtric/policy-agent repo for info about how to use it.
67
68 API Functins
69 ------------
70 See the following document for the Policy Agent API: nonrtric/policy-agent/docs/api.doc.
71
72 Near-RT RIC Simulator
73 =====================
74 A simulator that simulates a Neat-RT RIC, with a termination of the A1 interface. It also provides an administrative API to manage types and instances so it can be programatically set up for use in tests.
75
76 See the README.md file in the nonrtric/near-rt-ric-simulator repo for info about how to use it.
77
78 API Functions
79 -------------
80 See the admnistrative API in: nonrtric/near-rt-ric-simulator/ric-plt/a1/main.py.
81
82 Sdnc A1 Controller
83 ==================
84 An ONAP SDNC Controller for the A1 interface.
85
86 See the README.md file in the nonrtric/sdnc-a1-controller repo for info about how to use it.
87