This is the working code (taken from ZEDI) -
import sys
sys.path.append("<path_to_nmsdk_root>/lib/python/NetApp")
from NaServer import *
s = NaServer("<server name or IP address>", 1 , 17)
s.set_server_type("FILER")
s.set_transport_type("HTTPS")
s.set_port(443)
s.set_style("LOGIN")
s.set_admin_user("<user name>", "<password>")
api = NaElement("vserver-get-iter")
xo = s.invoke_elem(api)
if (xo.results_status() == "failed") :
print ("Error:\n")
print (xo.sprintf())
sys.exit (1)
print ("Received:\n")
print (xo.sprintf())