You can combine the "add_node.py" and "discover_and_add_interfaces.py" scripts in orionsdk-python sample scripts to add a node in NPM and also add interfaces that belong to this node. You'll have to modify these two lines in the code to specify nodeid instead of the default value in the sample script.
results = swis.invoke('Orion.NPM.Interfaces', 'DiscoverInterfacesOnNode', nodeid)
results2 = swis.invoke(
You'll also have to assign the correct pollers to get CPU and other statistics from the device that is added.
add_node_and_interfaces.py 2.6 KB