I have just started getting into understanding how the Commvault REST APIs work and the types of data and control that can be done with them.
I imported the collection into Postman, got logged in to the web server OK and can get output from all the basic GET commands, but have not been able to get some POST commands to work yet after trying a few. One that I am interested in working with is POST Testboot (and then also planned and unplanned failovers, so that I may orchestrate multiple failover groups).
The response is: “Request body is empty or format is invalid.”
Here is an example of my JSON body:
{
"taskInfo": {
"task": {
"taskFlags": {
"disabled": 0
},
"taskType": 1,
"ownerId": 1,
"initiatedFrom": 2,
"sequenceNumber": 0,
"ownerName": "admin"
},
"subTasks": {
"subTask": {
"subTaskType": 1,
"operationType": 4046
},
"options": {
"adminOpts": {
"drOrchestrationOption": {
"vApp": {
"vAppId": 40,
"vAppName": "2-other-svcs"
},
"advancedOptions": {
"skipDisableNetworkAdapter": 0
},
"operationType": 7,
"initiatedfromMonitor": 0
}
}
},
"subTaskOperation": 1
}
}
}