03-20-2018 11:51 AM
Getting 500 internal error for addSNMPUser. Anybody had a successful response?
2018-03-19 19:01:04,151 ucapi.cucmapi.CUCMAPI :81 - _send() - DEBUG receive 500 Internal Server Error
X-Frame-Options: SAMEORIGIN
Strict-Transport-Security: max-age=31536000; includeSubdomains
Content-Type: text/xml;charset=UTF-8
Content-Length: 371
Date: Mon, 19 Mar 2018 19:04:17 GMT
Connection: close
Server:
Body:
<?xml version="1.0" ?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault>
<faultcode>soapenv:Server</faultcode>
<faultstring/>
<detail>
<axlError>
<axlcode>-1</axlcode>
<axlmessage/>
<request>addSNMPUser</request>
</axlError>
</detail>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>
03-20-2018 12:38 PM
I could only get this request to work if I specified a list of hosts:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/11.5">
<soapenv:Header/>
<soapenv:Body>
<ns:addSNMPUser>
<user>
<userName>testSnmpUser2</userName>
<authRequired>true</authRequired>
<authPassword>password</authPassword>
<authProtocol>SHA</authProtocol>
<privacyRequired>true</privacyRequired>
<privacyPassword>password</privacyPassword>
<privacyProtocol>AES128</privacyProtocol>
<accessPrivilege>ReadOnly</accessPrivilege>
<snmpEngineID>localSnmpID</snmpEngineID>
<ArrayOfHosts>
<item>192.168.0.1</item>
</ArrayOfHosts>
</user>
</ns:addSNMPUser>
</soapenv:Body>
</soapenv:Envelope>
Omitting <ArrayOfHosts> or including an empty list resulted in the 500 error you showed...can you confirm this behaviour (likely a defect?)
03-20-2018 02:25 PM
Thanks. Looks like empty ArrayOfHosts will do as well. So, will go with that for now.
<privacyRequired>true</privacyRequired>
<ArrayOfHosts>
<item/>
</ArrayOfHosts>
<authProtocol>SHA</authProtocol>
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide