int ctMemphisPersistHardware( pRCESJson request, ppRCESJson result )
Description:
Persist a Hardware into the Replication Manager Database. If it doesn't exist, create it, otherwise updated it. In order to create a new one, the ID must be -1 or not passed. And the update will be done by the ID.
HTTP URL: <baseURL>/ctMemphisPersistHardware/
HTTP Verb: POST
Constraints:
Parameters:
{
"hardware": {
"id": -1, // optional, must be an
existing ID for update
"site": 0, // required
"name": "hardware3", // required
"macList": [ // required
{
"mac": "22-22-22-22-22-22",
"type": "ethernet"
},
{
"mac": "22-22-22-22-22-23",
"type": "ethernet"
}
],
"description": "hardware 3 description", // optional
"memory": 16, // optional
"diskSpace": 1000, // optional
"cpu": 8 // optional
}
}
{
"success": true,
"error":
{
"errorCode": 0,
"message": "Success"
},
"id": 2
}
Return:
Error code