I want to set a VM to a categorie, using the REST API.
However I Get the message INVALID_REQUEST
"Cannot clear previously set time zone
Don't know what to do with this.
Please note that I had to add the "power_state", because if I don't I get an INVALID_REQUEST
"VM power state must be specified for Update operation."
Which I dont understand, as API documentation saidpower_stateisoptional.
Endpoint used:PUT/vms/{uuid}
Body:
{
"spec": {
"name": "BACHELOR2018",
"resources": {
"power_state": "ON"
}
},
"api_version": "3.1",
"metadata": {
"kind": "vm",
"spec_version": 3,
"categories": {
"SLA": "A3"
}
}
}
Response body:
{
"api_version": "3.1",
"code": 422,
"message_list": [
{
"message": "Cannot clear previously set time zone",
"reason": "INVALID_REQUEST"
}
],
"state": "ERROR"
}