AnsweredAssumed Answered

API missing param hardware

Question asked by Brian Hill on Feb 7, 2018
Latest reply on Feb 8, 2018 by Yum Darling

When I do this:

curl -H "X-Samanage-Authorization: Bearer MYTOKEN" -d "{"hardware":{"owner":{"email":""}}}" -H "Accept: application/vnd.samanage.v2.1+json" -H "Content-Type:text/json" -X PUT

I get: {"error":"param is missing or the value is empty: hardware"}

If I do the same as xml:

curl -H "X-Samanage-Authorization: Bearer MYTOKEN" -d "<hardware><owner><email></email></owner></hardware>" -H "Accept: application/vnd.samanage.v2.1+xml" -H "Content-Type:text/xml" -X PUT

The owner of the hardware is properly updated.


What am I missing or doing wrong?


I get the same results with VBA as well, cannot do the JSON, but can the xml.