cisco-en-programmability / dnacentersdk

Cisco DNA Center Python SDK
https://dnacentersdk.readthedocs.io/en/latest/
MIT License
70 stars 33 forks source link

Attribute error #20

Closed mminnen closed 3 years ago

mminnen commented 3 years ago

Traceback (most recent call last): File "./dnac_assurance.py", line 17, in network_health= dnac.networks.get_overall_network_health(timestamp='') AttributeError: 'DNACenterAPI' object has no attribute 'networks'

Can be solved by adding version number '1.3.1.' to dnac instance creation or replace attribute networks with topology for API 2.x

jbogarin commented 3 years ago

@mminnen you can check the SDK API docs here. https://dnacentersdk.readthedocs.io/en/latest/api/api.html

networks changed to topology in 1.3.3, that's why you are getting the error. However, we have a new version of the SDK coming in the next 2 to 3 weeks with aliases between the old API classification and the new one according to the official docs in DNA Center Platform.