diff --git a/napalm/base/base.py b/napalm/base/base.py index e7226cba6..7c69c61b1 100644 --- a/napalm/base/base.py +++ b/napalm/base/base.py @@ -921,12 +921,23 @@ def get_ntp_servers(self) -> Dict[str, models.NTPServerDict]: """ Returns the NTP servers configuration as dictionary. The keys of the dictionary represent the IP Addresses of the servers. - Inner dictionaries do not have yet any available keys. + Inner dictionaries MAY contain information regarding per-server configuration. Example:: { - '192.168.0.1': {}, + '192.168.0.1': + { + 'address': '192.168.0.1', + 'port': 123, + 'version': 4, + 'association_type': 'SERVER', + 'iburst': False, + 'prefer': False, + 'network_instance': 'default', + 'source_address': '192.0.2.1', + 'key_id': -1, + }, '17.72.148.53': {}, '37.187.56.220': {}, '162.158.20.18': {} diff --git a/napalm/base/models.py b/napalm/base/models.py index 395c3c8dc..4afcb7bd0 100644 --- a/napalm/base/models.py +++ b/napalm/base/models.py @@ -232,7 +232,15 @@ NTPServerDict = TypedDict( "NTPServerDict", { - # will populate it in the future wit potential keys + "address": str, + "port": int, + "version": int, + "association_type": str, + "iburst": bool, + "prefer": bool, + "network_instance": str, + "source_address": str, + "key_id": int, }, total=False, )