1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. SPDX-License-Identifier: CC-BY-4.0
7 This document explains how to communicate with the A1 Mediator.
8 Information for maintainers of this platform component is in the Developer Guide.
13 Send the following JSON to create policy type 20008, which supports instances with
14 a single integer value:
20 "description": "tsa parameters",
21 "policy_type_id": 20008,
23 "$schema": "http://json-schema.org/draft-07/schema#",
31 "additionalProperties": false
36 Send the following JSON to create an instance of policy type 20008:
45 Integrating Xapps with A1
46 -------------------------
48 The schema for messages sent by A1 to Xapps is labeled ``downstream_message_schema``
49 in the Southbound API Specification section below. A1 sends policy instance requests
50 using message type 20010.
52 The schemas for messages sent by Xapps to A1 appear in the Southbound API
53 Specification section below. Xapps must use a message type and content appropriate
56 #. When an Xapp receives a CREATE message for a policy instance, the Xapp
57 must respond by sending a message of type 20011 to A1. The content is
58 defined by schema ``downstream_notification_schema``. The most convenient
59 way is to use RMR's return-to-sender (RTS) feature after setting the
60 message type appropriately.
61 #. Since policy instances can "deprecate" other instances, there are
62 times when Xapps need to asynchronously tell A1 that a policy is no
63 longer active. Use the same message type and schema as above.
64 #. Xapps can request A1 to re-send all instances of policy type T using a
65 query, message type 20012. The schema for that message is defined by
66 ``policy_query_schema`` (just a body with ``{policy_type_id: ... }``).
67 When A1 receives this, A1 will send the Xapp a CREATE message N times,
68 where N is the number of policy instances for type T. The Xapp should reply
69 normally to each of those as the first item above. That is, after the Xapp
70 performs the query, the N CREATE messages sent and the N replies
71 are "as normal". The query just kicks off this process rather than
72 an external caller to A1.
75 Northbound API Specification
76 ----------------------------
78 This section shows the Open API specification for the A1 Mediator's
79 northbound interface, which accepts policy type and policy instance requests.
80 Alternately, if you have checked out the code and are running the server,
81 you can see a formatted version at this URL: ``http://localhost:10000/ui/``.
84 .. literalinclude:: ../a1/openapi.yaml
89 Southbound API Specification
90 ----------------------------
92 This section shows Open API schemas for the A1 Mediator's southbound interface,
93 which communicates with Xapps via RMR. A1 sends policy instance requests using
94 message type 20010. Xapps may send requests to A1 using message types 20011 and
98 .. literalinclude:: a1_xapp_contract_openapi.yaml