Quantcast
Channel: THWACK: Popular Discussions - Orion SDK
Viewing all articles
Browse latest Browse all 3719

Python API add node?

$
0
0

Is it possible to add a node using the python api? I have been trying and have been unsuccessful. Here are the requests I've tried to perform:

 

Using API:

r = swis.create(Orion.Nodes, {"IPAddress = " + ip + "; EngineID = 1; ObjectSubType = " + objsubtype+ "; Caption = " + caption + ";"})

 

Using requests:

r = requests.request("POST", "https://solarwinds:17778/SolarWinds/InformationService/v3/Json/Create/Orion.Nodes", data=json.dumps("Orion.Nodes", {"IPAddress = " + ip + "; EngineID = 1; ObjectSubType = " + objsubtype+ "; Caption = " + caption + ";"}), verify=False, auth=(username, password), headers={'Content-Type': 'application/json'})

 

Unfortunately, all I have been able to get is a 500 response.Can anybody help?


Viewing all articles
Browse latest Browse all 3719

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>