+
+ @classmethod
+ def get_devices(cls, device_node, basic_auth: Dict[str, str]) -> int:
+ """
+ Get Devices on SDNC.
+
+ Returns:
+ the status of the sdnc component
+ """
+ url = f"{cls.base_url}/rests/data/network-topology:network-topology/topology=topology-netconf/node={device_node}"
+ status = cls.send_message('GET', 'Get status of Device connectivity', url, basic_auth=basic_auth)
+ return status.status_code
+
+ @classmethod
+ def get_events(cls, basic_auth: Dict[str, str], device):
+ """
+ Create device events in Sdnc.
+
+ Args:
+ topic: the event to create, in json format
+ :param basic_auth: (Dict[str, str]) for example:{ 'username': 'bob', 'password': 'secret' }
+ :param device:
+
+ """
+ url = f"{cls.base_url}/rests/operations/data-provider:read-faultlog-list"
+ return cls.send_message('POST', 'Get SDNC events', url, data='{"input": {"filter": [ {"property": "node-id", "filtervalue": "' + device + '"}],"sortorder": [{"property": "timestamp","sortorder": "descending"}],"pagination": {"size": 10,"page": 1}}}', basic_auth=basic_auth)