1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. http://creativecommons.org/licenses/by/4.0
3 .. Copyright (C) 2020 Nordix
5 .. _sdnc-a1-controller-api:
7 .. |nbsp| unicode:: 0xA0
10 .. |nbh| unicode:: 0x2011
17 The A1 of a Near |nbh| RT |nbsp| RIC can be used through the SDNC A1 Controller.
19 The OSC A1 Controller supports using multiple versions of A1 API southbound. By passing the full URL for each southbound
20 A1 operation the problem of version-specific URL formats is avoided.
22 Since different versions of A1 operations may use different data formats for data payloads for similar REST requests and
23 responses the data formatting requirements are flexible, so version-specific encoding/decoding is handled by the service
24 that requests the A1 operation.
39 /restconf/operations/A1-ADAPTER-API:getA1PolicyType
45 **Body:** (*Required*)
51 "near-rt-ric-url": "<url-to-near-rt-ric-to-get-type>"
59 A JSON object where the body tag contains the JSON object of the policy type. ::
63 "http-status": "integer",
73 Get a policy type from a Near |nbh| RT |nbsp| RIC that is using the OSC 2.1.0 version. The STD 1.1.3 version does not
74 support types, so this function is not available for that version.
78 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1PolicyType"
79 -H "Content-Type: application/json" -d '{
81 "near-rt-ric-url": "http://nearRtRic-sim1:8085/a1-p/policytypes/11"
93 \"$schema\": \"http://json-schema.org/draft-07/schema#\",
94 \"title\": \"Example_QoETarget_1.0.0\",
95 \"description\": \"Example QoE Target policy type\",
114 \"additionalProperties\": false,
121 \"type\": \"object\",
126 \"initialBuffering\": {
136 \"minProperties\": 1,
137 \"additionalProperties\": false
150 Creates or updates a policy instance.
157 /restconf/operations/A1-ADAPTER-API:putA1Policy
163 **Body:** (*Required*)
165 A JSON object where the body tag contains the JSON object of the policy. ::
169 "near-rt-ric-url": "<url-to-near-rt-ric-to-put-policy>",
170 "body": "<policy-as-json-string>"
178 A JSON object with the response. ::
182 "http-status": "integer"
191 Create a policy in a Near |nbh| RT |nbsp| RIC that is using the OSC 2.1.0 version. ::
193 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:putA1Policy"
194 -H "Content-Type: application/json" -d '{
196 "near-rt-ric-url": "http://nearRtRic-sim1:8085/a1-p/policytypes/11/policies/5000",
200 "trigger_threshold":10,
206 Create a policy in a Near |nbh| RT |nbsp| RIC that is using the STD 1.1.3 version. ::
208 curl -X POST http://localhost:8282/restconf/operations/A1-ADAPTER-API:putA1Policy
209 -H Content-Type:application/json -d '{
211 "near-rt-ric-url": "http://ricsim_g2_1:8085/A1-P/v1/policies/5000",
218 "priorityLevel": 5000
226 The result is the same irrespective of which API that is used.
242 Gets a policy instance.
249 /restconf/operations/A1-ADAPTER-API:getA1Policy
255 **Body:** (*Required*)
261 "near-rt-ric-url": "<url-to-near-rt-ric-to-get-policy>"
268 A JSON object where the body tag contains the JSON object of the policy. ::
272 "http-status": "integer",
284 Get **all** policy IDs from a Near |nbh| RT |nbsp| RIC that is using the OSC 2.1.0 version. ::
286 curl -X POST http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1Policy
287 -H Content-Type:application/json -d '{
289 "near-rt-ric-url":"http://ricsim_g1_1:8085/a1-p/policytypes/11/policies"
293 Get **all** policy IDs from a Near |nbh| RT |nbsp| RIC that is using the STD 1.1.3 version. ::
295 curl -X POST http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1Policy
296 -H Content-Type:application/json -d '{
298 "near-rt-ric-url":"http://ricsim_g2_1:8085/A1-P/v1/policies"
304 The result is the same irrespective of which API that is used.
323 Get **a specific** policy from a Near |nbh| RT |nbsp| RIC that is using the OSC 2.1.0 version. ::
325 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1Policy"
326 -H "Content-Type: application/json" -d '{
328 "near-rt-ric-url": "http://nearRtRic-sim1:8085/a1-p/policytypes/11/policies/5000"
332 Get **a specific** policy from a Near |nbh| RT |nbsp| RIC that is using the STD 1.1.3 version. ::
334 curl -X POST http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1PolicyType
335 -H Content-Type:application/json -d '{
337 "near-rt-ric-url":"http://ricsim_g2_1:8085/A1-P/v1/policies/5000"
343 The result is the same irrespective of which API that is used.
351 \"blocking_rate\": 20,
353 \"trigger_threshold\": 10,
354 \"window_length\": 10
365 Deletes a policy instance.
372 /restconf/operations/A1-ADAPTER-API:deleteA1Policy
378 **Body:** (*Required*)
384 "near-rt-ric-url": "<url-to-near-rt-ric-to-delete-policy>"
392 A JSON object with the response. ::
396 "http-status": "integer"
405 Delete a policy from a Near |nbh| RT |nbsp| RIC that is using the OSC 2.1.0 version. ::
407 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:deleteA1Policy"
408 -H "Content-Type: application/json" -d '{
410 "near-rt-ric-url": "http://nearRtRic-sim1:8085/a1-p/policytypes/11/policies/5000"
414 Delete a policy from a Near |nbh| RT |nbsp| RIC that is using the STD 1.1.3 version. ::
416 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:deleteA1Policy"
417 -H "Content-Type: application/json" -d '{
419 "near-rt-ric-url": "http://ricsim_g2_1:8085/A1-P/v1/policies/5000"
425 The result is the same irrespective of which API that is used.
441 Get the status of a policy instance.
448 /restconf/operations/A1-ADAPTER-API:getA1PolicyStatus
454 **Body:** (*Required*)
460 "near-rt-ric-url": "<url-to-near-rt-ric-to-get-policy-status>"
468 A JSON object where the body tag contains the JSON object with the policy status according to the API version used. ::
472 "http-status": "integer",
474 <policy-status-object>
484 Get the policy status for a specific policy from a Near |nbh| RT |nbsp| RIC that is using the OSC 2.1.0 version. ::
486 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1PolicyStatus"
487 -H "Content-Type: application/json" -d '{
489 "near-rt-ric-url": "http://nearRtRic-sim1:8085/a1-p/policytypes/11/policies/5000/status"
501 \"instance_status\": \"IN EFFECT\",
502 \"has_been_deleted\": \"true\",
503 \"created_at\": \"Wed, 01 Apr 2020 07:45:45 GMT\"
510 Get the policy status for a specific policy from a Near |nbh| RT |nbsp| RIC that is using the STD 1.1.3 version. ::
512 curl -X POST "http://localhost:8282/restconf/operations/A1-ADAPTER-API:getA1PolicyStatus"
513 -H "Content-Type: application/json" -d '{
515 "near-rt-ric-url": "http://ricsim_g2_1:8085/A1-P/v1/policies/5000/status"
527 \"enforceStatus\": \"UNDEFINED\"